openai / openai/codex

CLI: make AGENTS-relative skill paths unambiguous when cwd is a nested checkout

Open
#46,688 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug CLI skills
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

Summary

When an active AGENTS.md refers to a project-installed skill as .agents/skills/<name>/SKILL.md, an agent running from a nested checkout can incorrectly resolve that path against its process cwd instead of the directory that contains the applicable AGENTS.md.

Reproduction

  1. Arrange a workspace as follows:
workspace/
├── AGENTS.md
├── .agents/skills/beads/SKILL.md
└── checkout/
  1. Start Codex with workspace/checkout as the cwd while the parent workspace/AGENTS.md is active.
  2. Have AGENTS.md direct the agent to load .agents/skills/beads/SKILL.md.

Actual behavior

The relative path is easy to interpret as workspace/checkout/.agents/..., which does not exist, even though the skill registry exposes the canonical absolute skill location.

Expected behavior

Codex should expose an unambiguous canonical origin for every active AGENTS.md and canonical absolute paths for registered skills, or document/enforce that paths referenced by AGENTS.md are resolved relative to that file rather than cwd. This prevents unnecessary failed filesystem probes and makes project-level skill discovery deterministic.

Suggested direction

A codex debug agents-md/skill-resolution view could report the instruction-file origin and the resolved path for each referenced project skill.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing AGENTS.md discovery and project-skill resolution from the CLI, then reproduce the nested-checkout layout with workspace/checkout as cwd. Done means the instruction-file origin and registered skill paths are unambiguous, either through canonical output such as a debug view or documented enforcement of resolution relative to AGENTS.md.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.