Repository navigation
fix(docs): fail CI when the guide's versions drift; correct server ownership - #222
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5181a5201a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
5181a52 to
00fa9a0
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 00fa9a0d6c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 405c7c2948
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…nership Two docs-truth tests make version drift a CI failure: - Every QQ version in docs/guide and README.md must equal the workspace version; strings that are not QQ's go in FOREIGN_VERSIONS with a reason. - Every protocol, capabilities, descriptor and store-schema number the guide states must equal this build's, and design/protocol.md must name and describe the current PROTOCOL_VERSION. `cargo xtask release X.Y.Z` now rewrites the old version in those files and commits them with the bump, so a release keeps the guide passing. Fix what the tests found: stale 0.1.2/0.1.3 pins and samples, the doctor sample's protocol 27 / descriptor 9 / store schema 34, and design/protocol.md stuck at 28 with no 29/30 paragraphs. Also correct the server-ownership prose (checked on a build): - Quitting a TUI that started its own server cancels its runs; runs continue only under `qq serve`. - `qq run` never connects to a server. It exits 4 with "session store is owned by another running qq process" while a TUI or `qq serve` is open. Linear: ENG-979
…acked files only
- cargo xtask release rewrites only tracked, regular guide/README files
(from `git ls-files`), never an untracked draft or a symlink target.
- Foreign versions are exempt per line via a shared `<!-- not-qq-version -->`
marker that both the release rewrite and docs-truth honour, rather than
per (file, token). A stale QQ sample equal to a foreign token on the same
page now fails, and a QQ release equal to a foreign version leaves the
marked line alone.
- The compatibility check also reads the hyphenated `store-schema N`.
- Server-ownership prose, checked on a build:
- A second TUI attaches to the first TUI's server, and quitting the
first cancels runs from both.
- A concurrent `qq run` also holds the store and makes another exit 4;
separate data directories avoid it.
- Condense the GE0.1 ledger receipt to the workflow's 15-line limit.
Linear: ENG-979
v0.1.5 (#228) moved the rule: the bump PR must not move the guide's version pins, because the site deploys on merge before the tag's assets exist; a follow-up docs PR moves them. GE0.1's exact-equality check and bump-time rewrite contradicted that. - docs-truth: every QQ version in the guide and README is one version, the manifest's or the previous CHANGELOG.md release; stale or mixed pins still fail. - `cargo xtask release X.Y.Z` no longer rewrites docs. `cargo xtask release --docs` moves every pin from the previous release to the manifest version for runbook step 6 (no commit). - runbook documents both. Linear: ENG-979
6501e9a to
7f300be
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Base:
main(#186 merged; rebased onto v0.1.5). Bottom of the GE0 stack: this → #223 → #224. The first commit folds in the GE0 plan split that #186 did not carry.Slice GE0.1 of
docs/plans/guide-expansion.md· Linear ENG-979 (parent ENG-928).What changes for users
Four fixes to what the live docs site says:
qq serve. Aqqthat started its own server cancels its queued and running runs when it quits (history is kept).tui.mdnow has an Exiting section that explains both cases and how to keep runs alive.qq runand a running server. The site saidqq runconnects to the running server. It never does. It exits4withsession store is owned by another running qq processwhile a TUI orqq serveis open. This is now inheadless.md, the exit-code table, and a troubleshooting entry keyed on the real message.--versionsamples, and theqq doctorsample, which showed protocol 27 / store schema 34 (the build is 30 / 39).design/protocol.md. It saidPROTOCOL_VERSION = 28(the code is 30) and had no entries for 29 or 30. It now has both: 29 addsmaxand 30 addsdefault, each with its store schemas.How staleness is prevented from now on
Two new tests in
src/docs_truth.rs. They run incargo test, so CI fails on drift:every_product_version_in_the_guide_is_one_current_releasedocs/guide/andREADME.mdare not all one version, or that version is neitherCARGO_PKG_VERSIONnor the previousCHANGELOG.mdrelease. A string that is not QQ's version sits on a line ending with<!-- not-qq-version -->(the Codex client version); only that line is exempt.every_compatibility_number_in_the_guide_is_this_buildsprotocol N/capabilities N/descriptor N/store schema Nin the guide differs from this build's, ordesign/protocol.mddoesn't readPROTOCOL_VERSION = <current>and have aVersion <current> …paragraph.This follows the release rule from v0.1.5 (#228). The bump PR leaves the guide's pins alone, because the site deploys on merge, before the tag's assets exist. That is why the first test also accepts the previous release. After the assets are published, the new
cargo xtask release --docsmoves every pin at once (runbook step 6). It replaces whole tokens only:10.1.4,0.1.40and0.1.4.1are left alone, as the unit tests show. The bump itself no longer rewrites docs.Both tests failed first on the stale references (red), then passed after the fixes (green).
Verification
cargo xtask release 0.1.6left the pins on 0.1.5, and docs-truth passed.cargo xtask release --docsthen moved 9 references acrosscli.md,install.mdandtroubleshooting.md, and docs-truth passed again.HOME:qq serveplusqq rungives exit 4 and the quoted message.qq doctorsample matches real output.SessionRuntime::shutdowncancels every unfinished run; the existing testshutdown_cancels_running_and_queued_prompts_before_returningcovers it.cargo fmt --checkcargo clippy --workspace --all-targets --all-features -D warningscargo test --workspace(0 failures)nub run build(479 internal links resolve)Compatibility and performance
Docs and tests only, plus the release tool. No runtime, wire or store change, and no hot path touched.
Next in the stack
qq …and RON sample in the guide is executed against the real CLI and config loader in CI.Alt-Upand the six managed-only keys.