Skip to content

Keep Factory skill linking within checked worktree directories - #678

Merged
JacobStephens2 merged 2 commits into
mainfrom
issue-670
Oct 12, 2026
Merged

JacobStephens2 merged 2 commits into
mainfrom
issue-670

Conversation

@JacobStephens2

@JacobStephens2 JacobStephens2 commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

Summary

Sessions::within
  skills::link_into
    check project skills directories without following symlinks
    create missing directories relative to checked handles
    replace Factory skill entries relative to the checked directory
  start Harness only after linking succeeds

Closes #670

Evidence

  • Before: cargo test skills::tests::refuses_non_directory_skill_paths_without_changing_any_entries -- --exact --nocapture fails: Claude accepts a symlink at .claude.
    After: all four Factory skill tests and the session-start refusal test pass for every Adapter. The reviewer’s exact mode-0300 reproducer failed with Permission denied before the review fix and passes afterward; links_in_ordinary_directories_without_directory_read_permission retains that regression.

  • Formatting and cargo clippy --all-targets -- -D warnings pass. Final full suite: cargo test — 1740 passed, 0 failed, 2 existing ignored tests across 41 test binaries.

Seams under test: skills::link_into, Sessions::within, and the skills module's internal CheckedDirectory interface for deterministic directory replacement between checking and linking.

Unaddressed findings

  • Standards: none. Both fixture-duplication findings were addressed.
  • Spec: none. The directory-read-permission regression was reproduced with the reviewer’s exact command, fixed, and covered by a retained test.

Review coverage: both axes read all five changed files: src/session.rs, src/skills.rs, src/skills/directory.rs, src/skills/tests.rs, and src/test_support.rs. Unread changed files: none under Standards; none under Spec.

Merge Danger

Door: two-way

Blast Radius: sessions

Session startup refuses project skills paths containing symlinks or other non-directory entries. Ordinary and missing directory paths retain Factory skill linking.

Built with codex · gpt-6.1-sol · high

@JacobStephens2
JacobStephens2 marked this pull request as ready for review October 12, 2026 14:31
@JacobStephens2
JacobStephens2 merged commit b7c024f into main Oct 12, 2026
17 checks passed
@JacobStephens2
JacobStephens2 deleted the issue-670 branch October 12, 2026 14:47
@JacobStephens2 JacobStephens2 mentioned this pull request Oct 17, 2026
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.

Factory skill linking acts only inside the Run's own worktree

1 participant