Skip to content

fix(directives): read directives_path; inspect warns when it is missing - #120

Draft
aarontrowbridge wants to merge 1 commit into
mainfrom
opencode/issue-118-directives-path-read
Draft

aarontrowbridge wants to merge 1 commit into
mainfrom
opencode/issue-118-directives-path-read

Conversation

@aarontrowbridge

Copy link
Copy Markdown
Contributor

Closes #118

directives_path was parsed and displayed by arjev inspect but never read. load_directives now resolves, in order: $ARJEV_DIRECTIVES_FILE, then directives_path, then arjev-directives.md at the first root that has one. With neither set, behavior is unchanged.

arjev inspect reports a set-but-missing directives_path as an advisory warning: line (counted in fold warnings). It is deliberately not a blocked: line: inspect's blocking set is documented as closed (no feeds / no roots / zero identity-bearing notes) and the loader degrades to empty rather than failing. Easy to flip to blocking if preferred.

Evidence

  • New tests/test_directives_path.py (9 tests); 5 failed before the fix.
  • pytest: 295 passed. ruff check .: clean.
  • Docs: precedence in docs/agent-setup.md, entry under Unreleased in CHANGELOG.md.

Note: an ARJEV_DIRECTIVES_FILE that is set but missing still yields empty without fall-through (existing behavior; inspect does not warn about it).

@aarontrowbridge

Copy link
Copy Markdown
Contributor Author

Left as draft deliberately: this PR conflicts with night draft #116 (per-root field mapping) in src/arjev/inspect.py (3 hunks; _fold_lines signature and the warnings block). No conflict with #115 (directives.py, disjoint hunks). CI is green on this branch. Whichever of #116 / #120 lands second needs a small rebase in inspect.py; I did not rebase onto #116 because it is another agent's unmerged lane. Ready to mark ready on request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(directives): directives_path is parsed and shown by inspect but never read

1 participant