From 87d6e10fd309e66c0a3cd85d038c657f3c06effb Mon Sep 17 00:00:00 2001 From: Larry Klosowski Date: Thu, 12 Nov 2026 16:27:11 -0800 Subject: [PATCH] release: 0.9.0 (the r1007 network) Breaking (0.x minor): the vendored federation contract and the expected genesis are r1007's (#23), and an r1006 node is refused. - pyproject.toml, citrate_sdk.__version__ and the citrate-labs-sdk entry in uv.lock: 0.8.0 to 0.9.0. - CHANGELOG [0.9.0]. - README now names the r1007 book and genesis. Tests: pytest 966 passed, 8 skipped, including test_publish_metadata (__version__ equals the pyproject version) and the r1007 network guard. Not tagged or released: the lead tags after merge. Signed-off-by: Larry Klosowski Co-Authored-By: Claude Opus 5.5 (1M context) Claude-Session: https://claude.ai/code/session_019cgBjDQkjCEEZwG1zJNnQi --- CHANGELOG.md | 18 ++++++++++++++++++ README.md | 12 ++++++------ citrate_sdk/__init__.py | 2 +- pyproject.toml | 2 +- uv.lock | 2 +- 5 files changed, 27 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 35757d1..1926130 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,24 @@ All notable changes to `citrate-labs-sdk` are documented here. This project adhe ## [Unreleased] +## [0.9.0] - 2026-11-12: the r1007 network + +Breaking (0.x minor): the vendored address book and the genesis check move from r1006 to r1007 +(live 2026-11-12T14:00Z). A client or manager of this version refuses an r1006 node. + +### Changed + +- `citrate_sdk/_generated/federation_contract.json` is the r1007 federation contract + (citrate-federation#579, built from citrate-chain's root book). The expected genesis is r1007's + block 0, `0xcf68634502b4fca1e977ac8dd35aa006bb40c04208d5cd55f1c2b508bba96631`. + `CitrateClient`, the write-path managers (`pinned_send`) and + `verify_wallet_address_on_chain` raise `WrongNetworkError` (`WRONG_NETWORK`) on an r1006 node, + as they did on r1005. To keep talking to another network, pass `expected_genesis_hash=`. +- The block-0 contract and account-abstraction addresses are unchanged (CREATE2). The 28 + contracts deployed after block 0 (TenantHierarchy, the Quorum registries, the DefensePrime + registries and others) moved to the r1007 post-genesis deployer's addresses. The root book folds + them into `contracts()` under their own keys, for example `TenantHierarchy`. + ## [0.8.0] - 2026-11-08 — contract verification on CitrateScan Minor release: new API only, nothing removed or changed in an incompatible way. Publish once the diff --git a/README.md b/README.md index 3d36c49..6cc11a0 100644 --- a/README.md +++ b/README.md @@ -13,12 +13,12 @@ chain). It mirrors the canonical TypeScript SDK (`@citratelabs/sdk`) and may lag Tokenomics are not yet determined; see [docs.citrate.ai](https://docs.citrate.ai). -This release carries the **r1006** address book (citrate-chain -`contracts/addresses/r1006/40204.json`, genesis block `0xa3651a27…6cdd4`). Two networks can share -chain id 40204 (r1005 and r1006 do), so before the client or a manager sends a transaction, and +This release carries the **r1007** address book (citrate-chain's root book +`contracts/addresses/40204.json`, genesis block `0xcf686345…ba96631`). Several networks share +chain id 40204 (r1005, r1006 and r1007 do), so before the client or a manager sends a transaction, and before `verify_wallet_address_on_chain` trusts the factory, the SDK reads block 0 and raises `WrongNetworkError` (`error_code="WRONG_NETWORK"`) unless its hash is that genesis. -`client.verify_network()` runs the check up front. `LiquidStakingPool` is not in r1006 block 0, +`client.verify_network()` runs the check up front. `LiquidStakingPool` is not deployed on r1007 (nor on r1006), so `StakingManager` has no default address. See the concepts in the docs: . @@ -106,7 +106,7 @@ Point the SDK at a local Citrate stack on one machine instead of the public test client = CitrateClient( rpc_url="http://localhost:8545", private_key="0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80", # anvil acct #0 - expected_genesis_hash=None, # a local devnet is not the r1006 genesis + expected_genesis_hash=None, # a local devnet is not the r1007 genesis ) assert client.get_chain_id() == 40204 ``` @@ -218,7 +218,7 @@ forge and hardhat can verify against the same API directly. Two details matter o | `CITRATE_GATEWAY_API_KEY` | — | `cgk_` bearer key for the inference gateway | `CitrateClient(rpc_url, private_key=None, timeout=..., allow_insecure_http=False, chain_id=None, -expected_genesis_hash=)`. The expected chain id (40204), genesis hash (r1006) and +expected_genesis_hash=)`. The expected chain id (40204), genesis hash (r1007) and gateway base URL come from the vendored federation artifact; `citrate contract` prints the full table. The managers take the same `chain_id=` / `expected_genesis_hash=` keywords. diff --git a/citrate_sdk/__init__.py b/citrate_sdk/__init__.py index d2f6cb4..616d144 100644 --- a/citrate_sdk/__init__.py +++ b/citrate_sdk/__init__.py @@ -64,7 +64,7 @@ wait_for_verification, ) -__version__ = "0.8.0" +__version__ = "0.9.0" __author__ = "Citrate Team" __all__ = [ diff --git a/pyproject.toml b/pyproject.toml index f9c6a0c..11f7c77 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,7 +13,7 @@ build-backend = "setuptools.build_meta" [project] name = "citrate-labs-sdk" -version = "0.8.0" +version = "0.9.0" description = "Python SDK for the Citrate distributed AI network (chain 40204). The canonical TypeScript SDK is @citratelabs/sdk on npm; this Python client is opt-in and may lag it." readme = "README.md" requires-python = ">=3.10" diff --git a/uv.lock b/uv.lock index b076d06..bd1ca46 100644 --- a/uv.lock +++ b/uv.lock @@ -590,7 +590,7 @@ wheels = [ [[package]] name = "citrate-labs-sdk" -version = "0.8.0" +version = "0.9.0" source = { editable = "." } dependencies = [ { name = "cryptography" },