co-mono/packages
Aliou Diallo a9a1a62b14
fix(coding-agent): prevent global AGENTS.md from being loaded twice (#239)
When cwd is `~/.pi/agent/` or a subdirectory, the global AGENTS.md file
was included twice in the system prompt.

`loadProjectContextFiles()` loads context files in two steps:
1. Explicitly loads from `getAgentDir()` (`~/.pi/agent/`)
2. Walks from cwd up to root, collecting all AGENTS.md/CLAUDE.md files

There was no deduplication. When cwd is at or below `~/.pi/agent/`, the
ancestor walk includes that directory again.

Fix: track seen paths with a Set and skip duplicates.
2025-12-19 15:24:49 +01:00
..
agent Release v0.24.0 2025-12-19 05:21:25 +01:00
ai Release v0.24.0 2025-12-19 05:21:25 +01:00
coding-agent fix(coding-agent): prevent global AGENTS.md from being loaded twice (#239) 2025-12-19 15:24:49 +01:00
mom Release v0.24.0 2025-12-19 05:21:25 +01:00
pods Release v0.24.0 2025-12-19 05:21:25 +01:00
proxy Release v0.24.0 2025-12-19 05:21:25 +01:00
tui Release v0.24.0 2025-12-19 05:21:25 +01:00
web-ui Release v0.24.0 2025-12-19 05:21:25 +01:00