Skip to content

fix(setup): make resume.py correct from any working directory - #184

Open
jclarkfolklore wants to merge 1 commit into
gemini-cli-extensions:mainfrom
jclarkfolklore:fix/resume-py-invocation
Open

fix(setup): make resume.py correct from any working directory#184
jclarkfolklore wants to merge 1 commit into
gemini-cli-extensions:mainfrom
jclarkfolklore:fix/resume-py-invocation

Conversation

@jclarkfolklore

Copy link
Copy Markdown

The setup skill instructs python3 scripts/resume.py, but the script resolves conductor/ relative to the current working directory. No single working directory satisfies both.

Reproduce

From a project root — the script is not there:

$ python3 scripts/resume.py
can't open file '/path/to/project/scripts/resume.py': [Errno 2] No such file or directory

From the skill directory — the script runs, but reports on the skill directory rather than on the project:

$ cd skills/conductor-setup && python3 scripts/resume.py
{"setup_complete": false, "checklist": {...}}

Why this is easy to miss

In practice the agent recovers, because SKILL.md §1.2 tells it to "attempt to self-correct once" — so it finds a path that works and setup proceeds. Nothing appears broken.

The cost is that the resumption check is non-deterministic: which directory it reports on depends on how the model happened to resolve the path. A run that self-corrects toward the skill directory will report setup_complete: false for a project that is in fact already initialized, and §1.2 branches on exactly that value.

The change

determine_resumption() accepts the project root as argv[1], defaulting to os.getcwd() — so existing callers are unaffected. SKILL.md passes it explicitly and notes that a bare relative path cannot work.

Two files, +10/-2. No other behaviour changes.

Found while building on Conductor; the fix is upstreamed rather than carried privately, since it is a defect rather than a preference.

`conductor-setup` SKILL.md instructs `python3 scripts/resume.py`, but the script
resolves `conductor/` relative to the current working directory. No single
working directory satisfies both:

  # from a project root — the script is not there
  $ python3 scripts/resume.py
  can't open file '.../scripts/resume.py': [Errno 2] No such file or directory

  # from the skill directory — the script runs, but reports on the skill
  # directory rather than on the project
  $ cd skills/conductor-setup && python3 scripts/resume.py
  {"setup_complete": false, ...}

In practice this is invisible, because the agent self-corrects under the skill's
own "attempt to self-correct once" clause and finds a path that works. The cost
is that the resumption check is non-deterministic: which directory it reports on
depends on how the model chose to resolve the path.

`determine_resumption()` now accepts the project root as `argv[1]`, defaulting to
`os.getcwd()` so existing callers are unaffected, and SKILL.md passes it
explicitly with a note that a bare relative path cannot work.
@google-cla

google-cla Bot commented Sep 12, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull 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.

1 participant