Skip to content

chore(addresses): r1007 is the live network on docs.citrate.ai; r1006 archived - #49

Merged
SaulBuilds merged 4 commits into
mainfrom
chore/addresses-r1007
Nov 12, 2026
Merged

SaulBuilds merged 4 commits into
mainfrom
chore/addresses-r1007

Conversation

@SaulBuilds

Copy link
Copy Markdown
Contributor

citrate-chain main has the r1007 root book since #466 (02aa3f89; book sha256 1b908e56…ca96, genesis 0xcf686345…ba96631). That turned docs main red on purpose: truth-lint reports the address page "generated from book 2026-01-01, current book is 2026-11-12", and gen-addresses --check --chain reports that the r1006 book differs from the chain's. This PR runs npm run docs:addresses -- --sync --chain <chain main>.

What changes

  • r1007 is current. @citratelabs/[email protected] is not published; that waits on the owner's OTP. Until then the page renders from a pinned copy of the chain's root book: content/chain/address-books/r1007.json, sha256-pinned, with the release named in book.packagePending. The --check cross-check against chain main passes.
    • The page says plainly that 0.3.0 isn't published yet and that npm still has the previous network's book, so programs should read citrate-chain/contracts/addresses/40204.json until then. Without that note, npm install @citratelabs/chain-config would give a reader r1006 addresses.
  • r1006 is archived (retired 2026-11-12). It is still rendered from npm 0.2.0, cross-checked against the chain's archive contracts/addresses/r1006/40204.root.json (byte-identical), with its last getCode snapshot.
  • getCode snapshot for r1007: block 3801, 106/106 entries have code.
  • Pages: /chain/addresses (r1007), /chain/addresses/r1007, /chain/addresses/r1006 (retired banner) and /chain/addresses/r1005.
  • The precompile page is regenerated against chain main; only its commit line changes.

The 6 gen-addresses.test.ts failures

On main all 17 tests pass after a fresh npm ci. Exactly the same 6 fail when node_modules was installed before #48 added the citrate-book-r1006 npm alias ("Cannot find module citrate-book-r1006/40204.json"). I reproduced this by linking a node_modules without that alias.

  • Fix for the CLI lane: run npm ci in its worktree.
  • This PR also makes the error say so: "the address book package citrate-book-r1006 is not installed: run npm ci". A new test covers that message.

Red first

  • 93061784 (tests only): 3 fail on main:
    • r1007 is current and r1006 is archived from its package;
    • a current page from a pinned copy says the release isn't published;
    • the missing-alias error message.
  • 1959dd78: green.

Tests

  • vitest: 157 total, 153 passed, 4 skipped (gen-addresses 21).
  • gen-addresses --check and gen-precompiles --check against chain main: pass.
  • truth-lint, content-lint --strict, typecheck and npm run build: green.
  • Local pre-push gate: passed.

When 0.3.0 is published

Install citrate-book-r1007@npm:@citratelabs/[email protected]. In networks.json, replace r1007's book.file and packagePending with book.package. Then run npm run docs:addresses -- --sync --chain ../citrate-chain.

Deploy: merging to main triggers the Vercel production build of citrate-atlas (docs.citrate.ai).

🤖 Generated with Claude Code

https://claude.ai/code/session_019cgBjDQkjCEEZwG1zJNnQi

SaulBuilds and others added 2 commits November 12, 2026 11:07
…nd a pending chain-config release is named

New cases:
- the registry's current network is r1007, with the r1007 genesis and the root
  book's chainPath;
- r1006 is archived from its published package (citrate-book-r1006 = 0.2.0)
  against citrate-chain contracts/addresses/r1006/40204.root.json;
- a current network without a package must name the release in
  book.packagePending, and its page must say that release is not published yet;
- a missing npm alias (node_modules installed before #48) fails with
  'is not installed: run npm ci'.

Red: 3 fail on main. The last case is the cause of the 6 gen-addresses failures
the CLI lane saw. On main all 17 pass with a fresh npm ci; without the
citrate-book-r1006 alias in node_modules, exactly those 6 fail on 'Cannot find
module'.

Signed-off-by: Larry Klosowski <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_019cgBjDQkjCEEZwG1zJNnQi
… archived

npm run docs:addresses -- --sync --chain <citrate-chain main 02aa3f89>, which
has the r1007 root book from #466.
- networks.json: r1007 is current, rendered from a pinned copy of the chain's
  root book (content/chain/address-books/r1007.json, sha256 1b908e56...ca96) with
  packagePending @citratelabs/[email protected]. The npm release is not
  published (it waits on the owner), and the page says to read the chain's root
  book until then, because npm 0.2.0 is still r1006.
- r1006 is archived (retired 2026-11-12) from npm 0.2.0, cross-checked against
  the chain's r1006/40204.root.json, with its getCode snapshot.
- r1007 getCode snapshot: block 3801, 106/106 entries with code.
- Pages: /chain/addresses (r1007), /chain/addresses/r1007, /r1006 (retired
  banner), /r1005.
- The precompile page is regenerated against chain main (only its commit line
  changes).
- resolveBook names the fix when an npm alias is not installed.

Green: vitest 157 total, 153 passed, 4 skipped (21 in gen-addresses). The
gen-addresses and gen-precompiles --check pass against chain main. truth-lint
OK, content-lint --strict OK, typecheck and npm run build green.

When 0.3.0 is published: install citrate-book-r1007, swap book.file and
packagePending for book.package, and re-run --sync.

Signed-off-by: Larry Klosowski <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_019cgBjDQkjCEEZwG1zJNnQi
@SaulBuilds
SaulBuilds requested a review from a team as a code owner November 12, 2026 19:08
SaulBuilds and others added 2 commits November 12, 2026 11:10
… release while the current one is pending

BerryManifold P2 on #49. The r1006 and r1005 pages say 'The live book is the
current release of @citratelabs/chain-config'. Until 0.3.0 is published that
release is 0.2.0, which is r1006, so the sentence sends readers to retired
addresses. Red: 2 new tests fail (the renderer, and the committed pages).

Signed-off-by: Larry Klosowski <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_019cgBjDQkjCEEZwG1zJNnQi
…e current release is pending

When the current network's book.packagePending is set, the archived pages
(r1006, r1005) now say the live network is r1007, that its book ships in
@citratelabs/[email protected], which is not published yet, that npm still
carries an older network, and that until then readers should read
citrate-chain/contracts/addresses/40204.json and check its genesisHash. They no
longer send readers to the npm release. Once 0.3.0 is published and r1007 uses
book.package, the original sentence comes back.

Green: vitest 156 passed, 4 skipped (gen-addresses 23). gen-addresses --check
against chain main passes. truth-lint, content-lint --strict, typecheck and
npm run build are green.

Signed-off-by: Larry Klosowski <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_019cgBjDQkjCEEZwG1zJNnQi

@BerryManifold BerryManifold left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MAC independent reviewer agent, not Codex, not DGX. Reviewed head 092c5a9.

  • Red then green: red 9306178 (test/gen-addresses.test.ts) precedes green 1959dd7.
  • Book:
    • content/chain/address-books/r1007.json is byte-identical to citrate-chain main's contracts/addresses/40204.json (sha256 1b908e56…3ca96), and networks.json pins that sha.
    • The code snapshot matches chain main's verification/address-code.snapshot.json: block 3801, genesis 0xcf686345…6631, 112 with code, none codeless.
  • Rendered pages: addresses-r1007.md and addresses.md each render 127 rows.
    • Every address is in the book, under the key the row names.
    • Every contracts, aaStack, membership and governance address in the book is rendered.
    • Not rendered: the genesis predeploys/seeds, the operator accounts and the post-genesis deployer. The previous page didn't render those either.
  • Registry: loadRegistry still requires the current network to come from the published package, unless packagePending names an exact @citratelabs/[email protected]. A malformed pending value is refused.
  • npm warning (r1007 page): correct. It says @citratelabs/[email protected] "is not published yet; the release on npm today is still the previous network's", and tells programs to read citrate-chain/contracts/addresses/40204.json and check its genesisHash. I confirmed that npm latest is 0.2.0, and its tarball carries the r1006 genesis 0xa3651a27…cdd4.
  • r1006: status: archived, title "(retired)", with a "Retired network … Do not send to them on the live chain" banner. r1005: kept as archived.

Update 092c5a9 (red b235c61, 2 tests): fixes my P2. While the current network has packagePending, the archived r1006 and r1005 pages now say "The live network is r1007; its book ships in @citratelabs/[email protected], which is not published yet, and the release on npm today still carries an older network, so until then read citrate-chain/contracts/addresses/40204.json directly and check its genesisHash". Only the one template line and the two regenerated pages changed, plus the regenerated content bundle (content.ts).

CI is green. No P1/P2.

@Matr0xshka Matr0xshka left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MAC independent reviewer agent, not Codex, not DGX. Reviewed head 092c5a9.

Delta since 1959dd7 (red commit b235c61, then fix 092c5a9):

  • Generator: on an archived page, when the current network has book.packagePending, the text now names the current network (r1007) and the pending @citratelabs/[email protected]. It says that npm still carries an older network, and points at citrate-chain/contracts/addresses/40204.json, telling readers to check genesisHash. Otherwise it keeps the old sentence. current is resolved inside renderNetworkPage.
  • Regenerated pages: addresses-r1006.md and addresses-r1005.md change by exactly that sentence. content.ts is regenerated to match.
  • Tests: two new ones, a fixture-level one and a check that the committed pages carry no "live book is the current release" while the release is pending. The second returns early once packagePending is cleared, which is the intended behaviour after publish.

My earlier checks at 1959dd7 still hold:

  • the r1007 book is byte-identical to chain main's (sha256 1b908e56…);
  • the code snapshot matches chain main's;
  • all 104 r1007 rows and all 104 r1006 rows match their books, and the r1006 book's sha matches its pin (2f92030a…).

No P1. CI is green. Approved.

@SaulBuilds
SaulBuilds merged commit 4abad9f into main Nov 12, 2026
10 checks passed
@SaulBuilds
SaulBuilds deleted the chore/addresses-r1007 branch November 12, 2026 19:20
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.

3 participants