fix(opencode): grant opentui grammar cache - #251
Open
NoRiceToday wants to merge 3 commits into
Open
Conversation
Contributor
|
Should fix : test escapes the temp home when XDG_DATA_HOME is set. TestLaunchOpenCodeCreatesAndGrantsRuntimeDirs (internal/cli/continue_resume_test.go:266) doesn't neutralize an ambient XDG_DATA_HOME. I verified: with XDG_DATA_HOME=/some/dir the test fails and prepareSandboxDirs creates /some/dir/opentui on the developer's real machine. The sibling tests in serve_test.go/harness_test.go do t.Setenv("XDG_DATA_HOME", ""); launchCacheCaptureForHarness needs the same (or point it under home). |
added 3 commits
August 27, 2026 19:12
Signed-off-by: Sajjad Ahmad <sajjad.ahmad@tngtech.com>
Signed-off-by: Sajjad Ahmad <sajjad.ahmad@tngtech.com>
Signed-off-by: Sajjad Ahmad <sajjad.ahmad@tngtech.com>
mwtng
force-pushed
the
NoRiceToday/opencode-harness-markdown-renders-as-raw-text-ou
branch
from
August 27, 2026 17:21
781a8c6 to
c9bc9b1
Compare
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.
Issue: Closes #244
What
$HOME, including first-use grammar cache setup under default and custom XDG data roots.Why
How
$XDG_DATA_HOME, falling back to~/.local/share/opentui.startandservegrant resolution, then grant it read/write only for OpenCode.Verification
go test -buildvcs=false ./... -skip ^TestIntegration -count=1— passgo build -buildvcs=false ./...— passgo vet ./internal/config ./internal/cli ./internal/sandboxprofile— passgo test -buildvcs=false -tags=e2e ./internal/e2e -run ^$ -count=1— pass (compile check)git diff --check— passFollow-up
🤖 Generated with OpenCode (GPT-5.6 Sol).