Error: Unexpected error, #1506

Closed
opened 2026-02-16 17:31:17 -05:00 by yindo · 4 comments
Owner

Originally created by @karapy on GitHub (Aug 26, 2025).

Originally assigned to: @thdxr on GitHub.

When I try to run the opencode command, I encounter an error:
Error: Unexpected error, check log file at [user-home]/.local/share/opencode/log/2025-08-26T215857.log for more details

The log file contains the following details:

INFO  2025-08-26T21:58:57 +57ms service=default version=0.5.28 args=[] opencode
INFO  2025-08-26T21:58:57 +0ms service=app cwd=[project-directory] creating
INFO  2025-08-26T21:58:57 +1ms service=app git=[project-directory] git
ERROR 2025-08-26T21:58:57 +7ms service=default name=Error message=EACCES: permission denied, open '[user-home]/.local/share/opencode/project/[project-path]/app.json' fatal

The error indicates that OpenCode (version 0.5.28) is unable to access the app.json file in the directory [user-home]/.local/share/opencode/project/[project-path]/ due to a permission denied issue (EACCES). This suggests that the file or directory has incorrect permissions, preventing OpenCode from reading or writing to it. My goal is to completely uninstall OpenCode, as I initially attempted to remove it but continue to face this error when running the command.

Originally created by @karapy on GitHub (Aug 26, 2025). Originally assigned to: @thdxr on GitHub. When I try to run the `opencode` command, I encounter an error: `Error: Unexpected error, check log file at [user-home]/.local/share/opencode/log/2025-08-26T215857.log for more details` The log file contains the following details: ``` INFO 2025-08-26T21:58:57 +57ms service=default version=0.5.28 args=[] opencode INFO 2025-08-26T21:58:57 +0ms service=app cwd=[project-directory] creating INFO 2025-08-26T21:58:57 +1ms service=app git=[project-directory] git ERROR 2025-08-26T21:58:57 +7ms service=default name=Error message=EACCES: permission denied, open '[user-home]/.local/share/opencode/project/[project-path]/app.json' fatal ``` The error indicates that OpenCode (version 0.5.28) is unable to access the `app.json` file in the directory `[user-home]/.local/share/opencode/project/[project-path]/` due to a `permission denied` issue (EACCES). This suggests that the file or directory has incorrect permissions, preventing OpenCode from reading or writing to it. My goal is to completely uninstall OpenCode, as I initially attempted to remove it but continue to face this error when running the command.
yindo closed this issue 2026-02-16 17:31:17 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Aug 26, 2025):

This issue might be a duplicate of existing issues. Please check:

  • #359: Similar EACCES permission denied error with app.json file access issues on macOS with multiple user accounts
  • #1945: Permission-related installation errors, though this was specifically about Windows installation rather than runtime

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Aug 26, 2025): This issue might be a duplicate of existing issues. Please check: - #359: Similar EACCES permission denied error with app.json file access issues on macOS with multiple user accounts - #1945: Permission-related installation errors, though this was specifically about Windows installation rather than runtime Feel free to ignore if none of these address your specific case.
Author
Owner

@rekram1-node commented on GitHub (Aug 26, 2025):

how did you install opencode?

If this is really your goal:

My goal is to completely uninstall OpenCode

Then just rm rf these:

~/.local/share/opencode
~/.cache/opencode
~/.local/state/opencode
~/.config/opencode

and ofc rm whenever binary is

@rekram1-node commented on GitHub (Aug 26, 2025): how did you install opencode? If this is really your goal: > My goal is to completely uninstall OpenCode Then just rm rf these: ``` ~/.local/share/opencode ~/.cache/opencode ~/.local/state/opencode ~/.config/opencode ``` and ofc rm whenever binary is
Author
Owner

@karapy commented on GitHub (Aug 26, 2025):

~/.config/opencode

I installed using
curl -fsSL https://opencode.ai/install | bash

@karapy commented on GitHub (Aug 26, 2025): > ~/.config/opencode I installed using `curl -fsSL https://opencode.ai/install | bash`
Author
Owner

@rekram1-node commented on GitHub (Aug 26, 2025):

are you wanting to resolve this issue? Or are you just trying to delete? I have instructions for deleting.

If you wanna resolve issue what do you see when you run:

ls -la ~/.local/share/opencode/project/[project-path]/app.json
@rekram1-node commented on GitHub (Aug 26, 2025): are you wanting to resolve this issue? Or are you just trying to delete? I have instructions for deleting. If you wanna resolve issue what do you see when you run: ``` ls -la ~/.local/share/opencode/project/[project-path]/app.json ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#1506