fix(plugin): align OpenCode plugin SDK version and pin quota plugin#242
Merged
Merged
Conversation
Root package.json pinned 1.17.15 while .opencode/package.json pinned 1.18.4, causing compile-time hook-name guards to type-check against the wrong SDK. Aligned both to 1.18.4 and added a permanent parity check to validate-harness.sh. Fixes: #185 Authored-by: glm-5.2 Tested-by: deepseek-v4-pro Signed-off-by: kyau <git@kyaulabs.com>
The quota plugin was referenced unpinned in opencode.jsonc, letting the runtime resolve the latest from npm on every startup. Pinned it as an exact-version dependency in .opencode/package.json. Refs: #185 Authored-by: glm-5.2 Tested-by: deepseek-v4-pro Signed-off-by: kyau <git@kyaulabs.com>
…ouncements The quota plugin was declared in both opencode.jsonc and tui.jsonc; the tui.jsonc entry is a dead duplicate. Removed it. Disabled maintainerAnnouncements.enabled in quota-toast.json. Fixes: #185 Authored-by: glm-5.2 Tested-by: deepseek-v4-pro Signed-off-by: kyau <git@kyaulabs.com>
kyau
approved these changes
Jul 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📋 Summary
Three commits that together eliminate a
@opencode-ai/pluginSDK version skew between rootpackage.json(1.17.15) and.opencode/package.json(1.18.4), pin the previously unpinned@slkiser/opencode-quotaplugin to prevent supply-chain drift, and clean up dead config left over from the original quota-plugin integration.📦 Changes by Phase
Phase A — SDK version parity guard + alignment
.github/scripts/validate-harness.sh— addedcheck_sdk_version_parity()withget_sdk_version()helper, produces ERROR on mismatch, OK on alignment, skip if neither manifest declares the SDKpackage.json—@opencode-ai/pluginbumped1.17.15→1.18.4package-lock.json— regenerated vianpm installtests/Shell/validate-harness_test.sh— added Test 39 (mismatch → ERROR) and Test 40 (match → PASS)Phase B — Pin quota plugin
.opencode/package.json— added"@slkiser/opencode-quota": "4.0.1"(exact version, no range).opencode/package-lock.json— regenerated vianpm installtests/Shell/plugin_supply_chain_test.sh— Test 1 (exact version pinned), Test 2 (lockfile contains it)Phase C — Config cleanup
tui.jsonc— removed duplicate"plugin"key (already declared inopencode.jsonc)opencode-quota/quota-toast.json—maintainerAnnouncements.enabled:true→falsetests/Shell/plugin_supply_chain_test.sh— extended with Test 3 (no plugin key in tui.jsonc), Test 4 (announcements disabled)📜 ADRs
None new, amended, or superseded by this change.
✅ Verification
validate-harness_test.shplugin_supply_chain_test.shnpm run test:pluginvalidate-harness.sh(real repo)SDK version aligned: @opencode-ai/plugin@1.18.4 in both manifests@code-review🏗️ Architect Conditions (if applicable)
Not required per the pipeline — no cross-cutting ADR conditions were flagged by
@from-issueat triage time.📝 Commits (3 total)
Atomic, conventional-commits-formatted, signed. Not yet pushed.
5b9fb890f166246143921🧪 Test Plan
For reviewer verification:
bash tests/Shell/validate-harness_test.sh— verify 46 passed, 0 failedbash tests/Shell/plugin_supply_chain_test.sh— verify 4 passed, 0 failednpm run test:plugin— verify all 64 tests pass against SDK 1.18.4bash .github/scripts/validate-harness.sh— verify OK on SDK version parity linegrep '@opencode-ai/plugin' package.json .opencode/package.json— both show1.18.4