You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit c56fdeb
Browse filesBrowse the repository at this point in the historyBrowse files
fix(agent): carry the new codes into improve-rule, and correct four contract gaps
From review of #190. All five findings verified against the code before acting;
all five were real, and one was my own error.
`improve-rule.txt` was left on the old contract. `rule improve` goes through the
same service path as `rule create` and raises the same three codes — the new
`error-envelope` cases already assert that — but its recipe still listed "a
GitHub origin remote" as a precondition and documented only `NO_GITHUB_REMOTE`.
An agent following it in any no-remote population got an undocumented code and
no guidance, which is the exact failure this change set out to remove from
`rule create`. It now carries the same precondition check, the same three codes,
and the same note that `auth login` does not fix it.
The test that should have caught it named one recipe, so it could not. It is now
`it.each` over both, which is what makes the omission impossible to repeat.
`cli-rule-routing`'s spec said `route` reads the repository URL from `auth`. It
reads `ghOwner` from `info`; the `auth` wording predates moving those fields and
was never updated, so one scenario asserted the opposite of what was built and
of what every other spec in the change says. Corrected in the live spec and in
the archived delta.
Both touched recipes skipped their topic version bump, which `cli-agent`'s spec
requires on a meaningful change. `route` gained a whole step and a renumbering;
`create-remote-rule` gained a precondition section and three error rows.
Bumped to v3 and v2, and `improve-rule` with them.
`create-remote-rule` claimed four distinguishable causes. The throwing path
distinguishes three: the probe that would separate "git not installed" from
"not a git repository" is itself a `git` call, so a missing binary reports
`NOT_A_GIT_REPOSITORY`. Rather than claim a distinction the code cannot make,
the recipe now says so and tells the reader to check `PATH` when the user
insists the directory is a repository. `resolveRepositoryContext` is unaffected:
it never throws and reports `[unknown]` whatever the cause.
`resolveIdentity`'s docstring still named `NO_GITHUB_REMOTE` as the failure it
raises.
Refs #179
0 commit comments