Skip to content

Fix case-study runner: CWD-independent paths and clear task_repo error - #5

Merged
Rebell-Leader merged 1 commit into
mainfrom
claude/copilot-robustness-agnostic-ik1n1p
Jun 10, 2026
Merged

Rebell-Leader merged 1 commit into
mainfrom
claude/copilot-robustness-agnostic-ik1n1p

Conversation

@Rebell-Leader

Copy link
Copy Markdown
Owner

Summary

Follow-up to #4 (merged). Fixes two usability bugs in the case-study runner that
surfaced on a real run, rebased onto current main as a single commit.

What's fixed

  1. Runs from any directory. Config paths (prompt_file, workdir,
    copilot_repo) resolved against the current working directory, so the runner
    only worked from the project root and doubled paths
    (case-study/case-study/task/prompt.txt) when run from case-study/. They
    now resolve against the repo root derived from the script's location. Only the
    --config path stays relative to your shell.

  2. Clear error for an unset task_repo. The unedited placeholder
    (/path/to/task_ist_preprocessing) crashed with a raw FileNotFoundError
    deep in shutil.copytree. A real run now preflights task_repo and exits 2
    with an actionable message pointing at the config and the offline
    --mock-harness option.

Also: arms.example.json gains a _comment making the task_repo requirement
explicit; runner/README notes the run-from-anywhere behavior; 2 regression
tests added (CWD-independent path resolution; placeholder → exit 2).

Verification

  • 96 tests pass (1 skipped); generated agent files in sync
  • Verified all three previously-failing invocations: dry-run from case-study/,
    the placeholder error (exit 2), and --mock-harness from case-study/
  • Rebased onto current main (fast-forwardable, no conflicts)

https://claude.ai/code/session_01KedkjeNphkH8BvRYuGNDzq


Generated by Claude Code

…task_repo

Two usability bugs reported when running the runner:

1. Path issue: config paths (prompt_file, workdir, copilot_repo) resolved against
   the current working directory, so the runner only worked from the project
   root and doubled paths (case-study/case-study/task/prompt.txt) when run from
   case-study/. Now they resolve against the repo root derived from the script
   location, so it works from any directory. Only --config stays CWD-relative.

2. Unedited placeholder task_repo (/path/to/task_ist_preprocessing) produced a
   raw FileNotFoundError deep in shutil.copytree. A real run now preflights
   task_repo and exits 2 with an actionable message pointing at the config and
   the --mock-harness offline option.

- arms.example.json: add a _comment making the task_repo requirement explicit
- runner/README: note it runs from any directory and task_repo is required
- 2 regression tests (cwd-independent path resolution; placeholder -> exit 2)

96 tests pass; generated agent files in sync.

https://claude.ai/code/session_01KedkjeNphkH8BvRYuGNDzq
@Rebell-Leader
Rebell-Leader merged commit d18a881 into main Jun 10, 2026
12 checks passed
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.

2 participants