Skip to content

chore: export public API option types from the package entry#5

Merged
khaliqgant merged 1 commit into
mainfrom
chore/export-public-api-types
Jul 18, 2026
Merged

chore: export public API option types from the package entry#5
khaliqgant merged 1 commit into
mainfrom
chore/export-public-api-types

Conversation

@khaliqgant

@khaliqgant khaliqgant commented Jul 18, 2026

Copy link
Copy Markdown
Member

Why

Nine symbols are part of the public API surface but are not reachable from the
package entry. The exports map only exposes ".", so a consumer cannot
deep-import them either — they are unnameable.

Symbol Why it is public surface
StartMountOptions parameter type, SandboxOrchestrator method (orchestrator.ts:154)
FlushMountOptions parameter type, SandboxOrchestrator method (:272)
StopMountOptions parameter type, SandboxOrchestrator method (:288)
LocalSandboxRuntimeOptions constructor parameter of exported LocalSandboxRuntime (local/runtime.ts:45)
SandboxLookupOptions parameter type on the SandboxRuntime port (port.ts:43,47)
SandboxCountOptions parameter type on the SandboxRuntime port (port.ts:51)
RelayfileMountLifecycleShellOptions parameter type of the builder below
buildRelayfileMountLifecycleShell exported function (orchestrator.ts:334)
buildRelayfileMountCleanupInvocationShell exported function (orchestrator.ts:733)

A class whose constructor options type cannot be named, or a method whose
parameter type cannot be named, forces consumers to restate the shape by hand —
which then silently drifts from the real one.

Verification

  • Runtime exports resolve from the built entry: both build* functions are
    typeof === "function" when importing dist/index.js.
  • Type exports resolve through dist/index.d.ts: a probe module importing all
    seven types compiles clean under --module nodenext.
  • Package gates green: build, typecheck, 34 pass / 0 fail.

Export-list change only. No source, behavior, config, or CI changes.


Summary by cubic

Exported missing public API types and orchestrator shell builders from the package entry so consumers can import them directly. No runtime or config changes.

  • Refactors
    • Added exports in src/index.ts for StartMountOptions, FlushMountOptions, StopMountOptions, LocalSandboxRuntimeOptions, SandboxLookupOptions, SandboxCountOptions, RelayfileMountLifecycleShellOptions.
    • Exposed buildRelayfileMountLifecycleShell and buildRelayfileMountCleanupInvocationShell.

Written for commit 3e0e635. Summary will update on new commits.

Review in cubic

StartMountOptions, FlushMountOptions and StopMountOptions are parameter types
of public SandboxOrchestrator methods; LocalSandboxRuntimeOptions is the
constructor parameter of the exported LocalSandboxRuntime; SandboxLookupOptions
and SandboxCountOptions are parameter types on the SandboxRuntime port. None
were reachable from the package entry, and the exports map only exposes ".",
so consumers could not name them at all.

buildRelayfileMountLifecycleShell and buildRelayfileMountCleanupInvocationShell
are exported from orchestrator.ts but were likewise unreachable.
@coderabbitai

coderabbitai Bot commented Jul 18, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@khaliqgant, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 6 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 17e9dfaf-8cf3-42c0-92e5-eb0da606669e

📥 Commits

Reviewing files that changed from the base of the PR and between 4fb29c8 and 3e0e635.

📒 Files selected for processing (1)
  • src/index.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/export-public-api-types

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.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request exports several new types and functions from src/index.ts to expose them as part of the public API, including sandbox options, mount lifecycle shell builders, and mount options. Feedback suggests also exporting AsyncRunStartResult from ./port.js as it is part of the public API surface but currently missing from the package entry.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread src/index.ts
AsyncRunStatus,
DeclaredSandboxRuntimeCapabilities,
RunScriptResult,
SandboxCountOptions,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The type AsyncRunStartResult (defined in src/port.ts) is part of the public API surface as the return type of SandboxRuntime.startScript, but it is not exported from the package entry.

To ensure consumers can name this type, please add it to the exports from ./port.js in alphabetical order:

export type {
  AsyncRunStartResult,
  AsyncRunStatus,
  DeclaredSandboxRuntimeCapabilities,
  RunScriptResult,
  SandboxCountOptions,
  SandboxLookupOptions,
  SandboxRuntime,
  SandboxRuntimeCapabilities,
} from "./port.js";

@khaliqgant
khaliqgant marked this pull request as ready for review July 18, 2026 12:45
@khaliqgant
khaliqgant merged commit 5d053b6 into main Jul 18, 2026
2 checks passed
@cursor

cursor Bot commented Jul 18, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

@khaliqgant
khaliqgant deleted the chore/export-public-api-types branch July 18, 2026 12:45
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