Permission prompt appears when reading ~/.config/opencode/AGENTS.md #9409

Open
opened 2026-02-16 18:12:23 -05:00 by yindo · 1 comment
Owner

Originally created by @scarf005 on GitHub (Feb 15, 2026).

Problem

Image

When the agent tries to read ~/.config/opencode/AGENTS.md, OpenCode asks for external_directory permission (Access external directory ~/.config/opencode).

This path is OpenCode's own config directory and is already used as a first-class instruction source, so the extra external-directory prompt is unexpected and interrupts normal flows.

Reproduction

  1. Put an AGENTS.md in ~/.config/opencode/.
  2. Start a session in any project.
  3. Trigger a workflow where the model reads instruction files (for example asking it to investigate and read AGENTS files).
  4. Observe permission request: Access external directory ~/.config/opencode.

Expected

Reading instruction files from OpenCode-owned config paths should not trigger external_directory prompts.

Actual

A permission prompt appears for ~/.config/opencode.

Originally created by @scarf005 on GitHub (Feb 15, 2026). ## Problem ![Image](https://github.com/user-attachments/assets/d36cb060-5d51-4998-aee0-5337eb8b3c24) When the agent tries to read `~/.config/opencode/AGENTS.md`, OpenCode asks for `external_directory` permission (`Access external directory ~/.config/opencode`). This path is OpenCode's own config directory and is already used as a first-class instruction source, so the extra external-directory prompt is unexpected and interrupts normal flows. ## Reproduction 1. Put an `AGENTS.md` in `~/.config/opencode/`. 2. Start a session in any project. 3. Trigger a workflow where the model reads instruction files (for example asking it to investigate and read AGENTS files). 4. Observe permission request: `Access external directory ~/.config/opencode`. ## Expected Reading instruction files from OpenCode-owned config paths should not trigger `external_directory` prompts. ## Actual A permission prompt appears for `~/.config/opencode`.
Author
Owner

@github-actions[bot] commented on GitHub (Feb 15, 2026):

This issue may be related to or context for the following discussions:

  • #11454: Support .opencode/AGENTS.md for environment-specific instructions
  • #13346: Main agent often asking to access external_directory which is the one we are in (worktrees)
@github-actions[bot] commented on GitHub (Feb 15, 2026): This issue may be related to or context for the following discussions: - #11454: Support .opencode/AGENTS.md for environment-specific instructions - #13346: Main agent often asking to access external_directory which is the one we are in (worktrees)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9409