Skip to content

fix(opencode): remove the SDK dependency that pulls in tar - #2173

Merged
lizhengfeng101 merged 1 commit into
mainfrom
fix/opencode-tar-advisory
Dec 2, 2026
Merged

lizhengfeng101 merged 1 commit into
mainfrom
fix/opencode-tar-advisory

Conversation

@lizhengfeng101

Copy link
Copy Markdown
Contributor

Description

Remove @opencode/plugin from the OpenCode integration's development dependencies. It was only imported for its V2 context type, but it brought tar@7.5.22 into the plugin lockfile through pacote and node-gyp. This resolves GHSA-25mm-r35j-6hgm without forcing consumers of tar's v7 stream API onto an incompatible major version.

Type the V2 context against the tool, command, and session operations the integration actually uses. OpenCode still supplies that context at runtime. Both plugin entrypoints are unchanged, and the installation instructions no longer ask V2 users to install the redundant SDK.

Verification

  • Clean-installed the plugin dependencies and ran npm run check: 48 passed; the Windows-only test was skipped on macOS.
  • Type-checked the exported plugin against the previously pinned @opencode/plugin@0.0.0-beta-19425 contract.
  • Verified the regenerated lockfile has no tar package or dependency edge and introduces no new package versions.
  • Ran make check, make build, and make test (29 Go packages passed).

AI disclosure

OpenAI Codex CLI (gpt-6.2-astra) assisted with implementation, validation, and PR preparation. OpenCodeReview (gpt-6.2-astra) performed the pre-commit review.

@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

OpenCodeReview · Complete review: 2 of 2 selected files covered

0 findings.

Review info

Reviewed commits: c445fb4e377d7ece749468c0c80870deb60fe473 → af13eeb434ec1633a6b0f95f9ab33c43ab48f95a

File Result
plugins/open-code-review/opencode/package.json Reviewed
plugins/open-code-review/opencode/open-code-review.ts Reviewed

@css521 css521 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

@MuoDoo MuoDoo left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

@lizhengfeng101
lizhengfeng101 merged commit 24b1a3b into main Dec 2, 2026
14 checks passed
@lizhengfeng101
lizhengfeng101 deleted the fix/opencode-tar-advisory branch December 2, 2026 13:10
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.

3 participants