Skip to content

fix(publish): pack the full internal closure with rewritten specifiers - #11

Merged
dallenpyrah merged 1 commit into
v2from
publish-closure
Sep 17, 2026
Merged

dallenpyrah merged 1 commit into
v2from
publish-closure

Conversation

@dallenpyrah

Copy link
Copy Markdown

Summary

  • Compute the umbrella package's internal closure from runtime src/ imports instead of a hardcoded list (23 packages, including ai, tui, theme, codemode, simulation, plugin-browser)
  • Rewrite @opencode/* specifiers to relative paths at pack time so the tarball resolves under Node/vitest, not only Bun
  • Resolve each package through its own exports map: exact keys, wildcard keys with longest-prefix precedence, and direct asset targets like ./audio/*.mp3
  • Ship only src/ + package.json per internal package
  • Remove the unused Actors surface and @rivetkit/effect dependency from packages/rivet

Test plan

  • OPENCODE_VERSION=9.9.9-test bun ./script/publish-rikalabs.ts packs cleanly; no remaining @opencode/* runtime specifiers in the tarball
  • Packed tarball installed into whorl via file: — lint, typecheck, db check, and full @whorl/actors suite (sql + postgres + process) pass against it
  • bun run check green (38 typecheck tasks, 0 lint warnings)

Generated with Devin

The umbrella tarball only shipped a hardcoded package list and relied on
a non-"#" imports map that Bun alone resolves, so Node/vitest consumers
failed on every @opencode/* specifier. Compute the closure from runtime
src/ imports, honor each package's own exports map (exact, wildcard with
longest-prefix precedence, asset paths), and rewrite internal specifiers
to relative paths at pack time. Drop the unused Actors surface and its
@rivetkit/effect dependency from packages/rivet.
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@github-actions

Copy link
Copy Markdown

Thanks for your contribution!

This PR doesn't have a linked issue. All PRs must reference an existing issue.

Please:

  1. Open an issue describing the bug/feature (if one doesn't exist)
  2. Add Fixes #<number> or Closes #<number> to this PR description

See CONTRIBUTING.md for details.

@github-actions

Copy link
Copy Markdown

This PR doesn't fully meet our contributing guidelines and PR template.

What needs to be fixed:

  • PR description is missing required template sections. Please use the PR template.

Please edit this PR description to address the above within 2 hours, or it will be automatically closed.

If you believe this was flagged incorrectly, please let a maintainer know.

@github-actions

Copy link
Copy Markdown

The following comment was made by an LLM, it may be inaccurate:

@dallenpyrah
dallenpyrah merged commit b240d5e into v2 Sep 17, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant