Repository navigation
fix: write the recall allow as a V1 permission rule so OpenCode V1 1.19+ starts - #122
Draft
MaheshtheDev wants to merge 1 commit into
Draft
MaheshtheDev wants to merge 1 commit into
MaheshtheDev wants to merge 1 commit into
Conversation
…19+ starts Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
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.
The installer added the OpenCode 2 rule
"permissions": [{ "action": "supermemory_recall", "resource": "*", "effect": "allow" }]to the shared~/.config/opencode/opencode.jsonc. OpenCode V1 1.19.0 and later refuse to start when that key is present:This happened on a clean
opencode-supermemory@2.1.0 installwithopencode-ai@1.19.5during the SCR-325 plugin end-to-end pass.The installer now writes the V1 form,
"permission": { "supermemory_recall": "allow" }. OpenCode V1 accepts it, and OpenCode 2 converts it into exactly the old V2 rule. Configs written by earlier versions are repaired on the next install: our own V2 allow is removed frompermissions(the key is dropped if nothing else is left), and any other user rules stay. An explicit deny in either form is still preserved with a warning, andstatusreports the recall rule from either form.Verified with
opencode debug config/opencode2 debug configon the config the installer now produces:permission.supermemory_recall = "allow"[{"action":"supermemory_recall","resource":"*","effect":"allow"}]bun test(34 pass) andbun run typecheckare clean. OpenCode V1 1.17 and 1.18 still reject the shared file, because they don't recognise thepluginskey at all. That limitation predates this change and is not addressed here.