Skip to content

Typecheck terminal artifact grants - #27420

Merged
nwparker merged 1 commit into
mainfrom
nwparker/runtime-file-grants
Oct 14, 2026
Merged

nwparker merged 1 commit into
mainfrom
nwparker/runtime-file-grants

Conversation

@nwparker

@nwparker nwparker commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 1 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​171 0 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​171
Prod 15 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​530 $\color{#cf222e}{\Huge{\mathbf{−}}}$​451 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​79

ELI5

Type errors now surface in terminal artifact grants. Users keep the same behavior.

What Changed

Removes 5 unchecked-file baseline entries. Replaces unchecked assumptions with types from the existing producers and installed services. Moves include src/main/runtime/runtime-file-commands-assert-remote-terminal-file-grant-path-still-canonical.ts → src/main/runtime/runtime-file-explorer-watch-commands.ts, src/main/runtime/runtime-file-commands-terminal-artifact-access.ts → src/main/runtime/runtime-terminal-artifact-integrity.ts.

Why

Keep contracts tied to the code that implements them, without a broad assertion on the runtime or a duplicate host model.

Linked Issue

N/A — maintainer restructuring.

Visual Proof

N/A — no visual or interaction change.

Testing

All 32 runtime stages passed the main/runtime typecheck. Four compiler projects and 2,029 affected tests under each runner passed (one existing skip); the packaging prerequisite leaves those TypeScript inputs unchanged.

The cumulative stack at 5c731f58 passed the full five-shard unit run: 116,625 tests passed, with no unhandled errors. Actual macOS arm64 and Windows packages passed CLI checks; macOS also covered folder workspaces, measured terminal sizing and an older managed SSH peer, and Windows covered ConPTY cleanup and packaged/standalone host commands. The actual Linux AppImage passed the canonical Ubuntu 20.04 runtime-floor check.

Separate full mobile verification also passed. The complete hosted run also passed: changed E2E, managed SSH (38 passed, two explicit skips), layout (21 passed) and terminal sizing (18 passed). In one matched CI pair, preflight took 179 seconds before and 192 seconds after; the slowest unit job took 620 and 613 seconds. The baseline’s unchanged 1ms-sensitive assertion passed one targeted retry. Queue and retry time remain separate; no overall speedup is claimed. Individual PR checks are tracked separately from this cumulative evidence.

Review

Merge 2/33, after nwparker/runtime-codex-toml-package. Human review and merge only; no auto-merge.

Agent skill upstream boundary

  • Not applicable; no upstream skill source is copied.

Notes

Execution-host ownership and mixed-peer behavior are preserved. Final validation includes Windows, SSH and folder workspaces.

Checklist

  • Explained the behavior, mechanism and approach.
  • No visual change; relevant local checks pass.
  • Reviewed initialization, compatibility and execution ownership.
  • Final-stack macOS, Windows and Linux runtime-floor checks complete.
  • Full-stack hosted CI passed; individual PR results are available in the Checks tab.

@coderabbitai

coderabbitai Bot commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 45 seconds.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: d18777a3-870b-4736-b7de-a0264b6b4d36
📥 Commits

Reviewing files that changed from the base of the PR and between e902002 and e315782.

📒 Files selected for processing: 16
  • config/ts-nocheck-baseline.txt
  • src/main/runtime/runtime-file-command-access.ts
  • src/main/runtime/runtime-file-commands-mobile-file-list-limit.ts
  • src/main/runtime/runtime-file-commands-read-file-explorer-preview.ts
  • src/main/runtime/runtime-file-commands-read-mobile-file.ts
  • src/main/runtime/runtime-file-commands-resolve-allowed-terminal-artifact-path.ts
  • src/main/runtime/runtime-file-commands-revoke-terminal-file-grants-for-client.ts
  • src/main/runtime/runtime-file-commands-terminal-file-paths.ts
  • src/main/runtime/runtime-file-commands-write-terminal-artifact-file.ts
  • src/main/runtime/runtime-file-explorer-watch-commands.ts
  • src/main/runtime/runtime-terminal-artifact-integrity.ts
  • src/main/runtime/runtime-terminal-artifact-stat.ts
  • src/main/runtime/runtime-terminal-artifact-write.ts
  • src/main/runtime/runtime-terminal-artifacts.ts
  • src/main/runtime/runtime-terminal-file-grants.test.ts
  • src/main/runtime/runtime-terminal-file-grants.ts

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ce66bd8a-2a8f-4e91-b6c8-d7a24c085061
📥 Commits

Reviewing files that changed from the base of the PR and between fac6977 and e902002.

📒 Files selected for processing: 3
  • src/main/runtime/runtime-file-command-access.ts
  • src/main/runtime/runtime-file-commands-mobile-file-list-limit.ts
  • src/main/runtime/runtime-terminal-artifacts.ts
💤 Files with no reviewable changes: 1
  • src/main/runtime/runtime-file-commands-mobile-file-list-limit.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.

📝 Walkthrough

Terminal artifact grant management and artifact operations now reside in dedicated runtime modules. The changes add grant creation, validation, refresh, revocation, and expiry, plus artifact path resolution, stat, reads, previews, and guarded writes. Runtime file command access delegates these operations to RuntimeTerminalArtifacts. Related command implementations and grant declarations are removed, and file-explorer inheritance and TypeScript no-check baseline entries are updated.

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to e9020

This refactor moves terminal file-link grant and artifact handling into dedicated modules without a visible behavior change. No concrete merge-blocking risk was found in the supplied context, and the full CI results reported by the author are still pending.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 23.53% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 17 functions across 12 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Title check Passed The title clearly identifies the main change: enabling type checking for terminal artifact grants.
Description check Passed The description includes the required sections, explains the refactor and rationale, documents testing, and addresses visual proof and review items. The maintainer-specific absence of a linked issue a…
✨ Finishing Touches: 💡 1
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@nwparker
nwparker force-pushed the nwparker/runtime-file-grants branch from fac6977 to e902002 Compare October 13, 2026 18:36
@nwparker nwparker changed the title refactor(runtime): compose typed terminal artifact grants Typecheck terminal artifact grants Oct 13, 2026
@nwparker
nwparker force-pushed the nwparker/runtime-file-grants branch from e902002 to d76a9be Compare October 13, 2026 20:53
@nwparker
nwparker changed the base branch from main to nwparker/runtime-codex-toml-package October 13, 2026 20:54
@nwparker
nwparker force-pushed the nwparker/runtime-file-grants branch from d76a9be to e315782 Compare October 14, 2026 01:05
@nwparker
nwparker changed the base branch from nwparker/runtime-codex-toml-package to main October 14, 2026 01:05
@nwparker nwparker closed this Oct 14, 2026
@nwparker nwparker reopened this Oct 14, 2026
@nwparker
nwparker force-pushed the nwparker/runtime-file-grants branch from e315782 to 93cd6ad Compare October 14, 2026 07:58
@nwparker

Copy link
Copy Markdown
Contributor Author

Rebased again onto current main, which had moved 69 commits. Conflict in runtime-file-command-access.ts: kept the PR's RuntimeTerminalArtifacts import and added main's RuntimeFileOpenPosition import (#28240).

@nwparker
nwparker merged commit 39e70c1 into main Oct 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant