release: v0.1.0 final polish — API freeze, doc truth, offline benches, live-verified - #34
Merged
Conversation
Module-scope sol! blocks generate pub items, so ~30 internal ABI types (quote-call structs, event decls, factory events) rendered on docs.rs as public API and froze ABI plumbing into the semver surface. Wrap each block in a crate-internal mod: sim's quote ABI is pub(crate) (cross-module consumers), event bindings are module-private, matching the existing pancake_v3/solidly_events idiom. The RPC-parity and WS-soak tests that borrowed these bindings now declare their own local sol! ground-truth ABI. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- pub use alloy_primitives / evm_fork_cache at the root: both appear irreducibly in the public API (EvmCache, reactive runtime, Address/U256), so downstream can name them without hand-pinning matching versions. Documents the evm-fork-cache 0.x lockstep policy. - [package.metadata.docs.rs] rustdoc-args --cfg docsrs + feature(doc_cfg) (auto-cfg, post-1.92 form): gated items now render 'Available on crate feature X' badges on docs.rs. - Export V3StorageLayout/SolidlyStorageLayout at the adapters root unconditionally (both always compiled; V3StorageLayout is a root-exported metadata field type). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- #[non_exhaustive] on the cold_start/bytecode/state mirror structs (ColdStartPlan and friends) so upstream field additions — e.g. the pending root-probe planner phase — land without breaking downstream; each type documents its construction path and gained a constructor (new/with_*) where Default + assignment wasn't enough. - BytecodeTemplateError joins the crate's other error enums as non_exhaustive; SlotDelta documents why it deliberately stays exhaustive. - Fix the find_many doc-merge artifact (stale internal doc block was the rustdoc summary line) and the stale 'from = ZERO' claim on AmmAdapter::simulate_swap (SimConfig::from is threaded through since tier-2). - Tests/examples switch to the new constructors (external crates can no longer literal-construct the mirrors — that is the point). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… ViewCall The last merged PRs (#30/#31/#33) outran four shipped docs: CHANGELOG, README (intro + protocol table), protocol-support-matrix, and trace-backed-sync still described Balancer Swap (and partly V3 Mint/Burn) as resync-only, and the changelog omitted Balancer swap event-sourcing, the verify-only cold-start fast path, CurveMetadata::with_code_seed, the Balancer/Curve cold_start_many bundling, and the new stateDiff parity suites. Also removes the MetaRegistry/ViewCall discovery mechanism that 3a197f3 dropped from code but three docs kept describing, and the unused Cargo.toml link def. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- writing-an-adapter: the AmmAdapter table was missing pool_factories and code_seeds and claimed 'six defaulted' methods (nine); custom_adapter's header repeated the six. - high-performance-bootstrap-defaults: past-tense the superseded 'currently' narrative (batched discovery + cold_start_many shipped) and mark checklist item 1 Done. - benchmarks.md: cargo bench does NOT emit HTML reports in this build (criterion without plotters; gnuplot only) and mean/median need --verbose; align the trace-resync reproduce command with the seven-iteration run it documents; stamp the results as the v0.1.0 candidate. - One auditable CU figure for the V3 full-sync comparison everywhere (7,674 reads x 17 CU ~= 130k; README/CHANGELOG said 153k, the example 134k). - bytecode_golden header: make explicit the file itself needs no env. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ested quickstart - crates.io / docs.rs / CI / license / MSRV badges - Installation section: cargo add, feature trimming, MSRV 1.88, and the public-dependency re-export policy (evm_fork_cache / alloy_primitives at the root, lockstep releases) - 12-example index with a zero-setup 'start here' entry point - Slipstream quoting caveat surfaced beside the Solidly one (matches the support matrix); 'all protocol features on by default' corrected (pancake-v3/slipstream are uniswap-v3 aliases) - README code samples compile as doctests via a cfg(doctest) include (quickstart flipped ignore -> no_run; verified by cargo test --doc) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- V3 apply_liquidity_delta and Balancer apply_cash_delta get exact-boundary unit tests: filling to u128::MAX / 2^112-1 is representable, one unit past is None (resync fallback) — never wrap/saturate/carry into a co-tenant field; oversize amounts are rejected up front. - Solidly V2 joins the AmmSyncEngine coverage (it was the only protocol with no engine/WS test): a Sync ingests as two exact reserve writes with zero resync work, proven by panicking trace/storage fetchers. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… rows New benches/reactive_apply.rs (criterion, no env, mock-backed EvmCache with pre-warmed packed words — the adapter_reactive.rs fixtures) measures the event-sourced hot paths end-to-end through AdapterDriver::apply_log: v2_sync ~283 ns (agrees with the RPC-warmed ~249 ns) balancer_swap_two_token ~432 ns balancer_swap_general ~519 ns v3_mint_warm ~1.42 us v3_burn_warm ~1.35 us Headroom-sized initial state keeps millions of iterations on the warm path (burns never empty the tick, cash never leaves its 112-bit field), and pre-flight asserts pin exact writes before measuring. benchmarks.md's reactive table now carries all five paths instead of scoping everything to the single V2 row, and documents the offline reproduce command. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
sync_latency and curve_cold_start_phases run multi-iteration cold-start loops; on the publicnode fallback a rate limit aborts them mid-run with a bare transport error. Say so up front and point at E2E_RPC_URL. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
RUSTSEC-2025-0055 (tracing-subscriber 0.2.25) resolves into Cargo.lock via revm-precompile's optional arkworks bn254 backend, which no feature of this crate ever enables — cargo tree finds it in no build graph, even with --target all --all-features. Ignore it with the justification checked in, so cargo audit is green and gateable. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
RELEASING: the live suites are now a required step covering all eight gated files (was 'optional' naming three), the package is 56 files / seven guides, the tag section documents the re-point procedure the v0.1.0 prep needed, and the post-publish section drops the CI-auth cleanup that already happened in favor of docs.rs badge checks and seeding the live workflow. ROADMAP: factory discovery shipped in 0.1.0 (the plan still promised it for 0.2.0 with pre-implementation API names); the 0.1.x/0.2.0 section now lists the real candidates — PR #32 access-list warming, Balancer log-scan + Curve MetaRegistry discovery, PoolBalanceManaged subscription, Algebra forks, Bootstrapper, incremental interests. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Deleting factory.rs's 'use alloy_sol_types::sol;' left its cfg(uniswap-v2|uniswap-v3) attribute behind, which stacked onto the ProtocolMetadata import below and compiled it out of solidly-2-only builds — caught by the isolation clippy matrix, the exact bug class it exists for. Also allow the sim::abi re-export to be unused in the bare adapters-only build (all its consumers are feature-gated out there). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ocker evm-fork-cache 0.2 already ships the incremental interests API (ReactiveRuntime::unregister_handler; add_interest_owner(_with_backfill) / remove_interest_owner / sync_handler_interests on the subscription engine). The stale 'once the upstream API lands' framing survived from the pre-0.2 roadmap; the real remaining work is on this side — AmmSyncEngine still rebuilds a fresh ReactiveRuntime per registry change, discarding reorg tracking, instead of refreshing the handler registration in place. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The quickstart registers the V3-family adapter, so compiling it under --no-default-features failed the doctest phase (caught by the battery's CI-parity test-nodefault gate). Default and all-features runs still compile it. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes out every finding from the full pre-release review (docs, API surface, tests, benches, release mechanics) so v0.1.0 can be re-tagged and published from a state where nothing cheap-to-fix-now becomes breaking-later.
API surface (free today, breaking once a downstream exists)
sol!bindings privatized — module-scopesol!generatespubitems, so ~30 internal ABI types (quote-call structs, event decls, factory events) rendered on docs.rs as public API. Each block now lives in a crate-internalmod abi(the existingpancake_v3/solidly_eventsidiom); the RPC-parity/WS tests that borrowed them declare their own local ground-truth ABI.pub use evm_fork_cache;+pub use alloy_primitives;at the root, with the 0.x lockstep policy documented: downstream no longer hand-pins matching versions to nameEvmCacheorAddress.rustdoc-args = ["--cfg", "docsrs"]+feature(doc_cfg)(post-1.92 auto-cfg): gated modules/items now render "Available on crate feature …" badges.#[non_exhaustive]gaps closed on the cold_start/bytecode/state mirror structs (with documented constructors —ColdStartPlanalready had a pending upstreamprobe_rootsfield waiting to break planner authors),BytecodeTemplateErrorjoins the other error enums,SlotDeltadocuments why it deliberately stays exhaustive.find_many's doc-merge artifact (stale block was the rustdoc summary),simulate_swap's stalefrom = ZEROclaim,V3StorageLayout/SolidlyStorageLayoutexported at the root unconditionally.Shipped-docs truth pass
[0.1.0], README (intro + protocol table),protocol-support-matrix.md, andtrace-backed-sync.mdall still said BalancerSwap→ resync (pre-Event-source Balancer V2 swaps #33) — now they describe the event-sourced exact cash writes, and the changelog gains the omitted features (Event-source Balancer V2 swaps #33 event-sourcing, perf(cold-start): verify-only fast path for Curve + Balancer (+ optional Curve code seed) #31 verify-only fast path,CurveMetadata::with_code_seed, Balancer/Curvecold_start_manybundling, the new stateDiff parity suites).pool-discovery.md/CHANGELOG still described the MetaRegistry/ViewCall discovery mechanism dropped in3a197f3.writing-an-adaptertable gains the missingpool_factories/code_seedsrows ("six defaulted" → nine),high-performance-bootstrap-defaultspast-tenses its superseded narrative and marks checklist item 1 done, benchmarks.md no longer promises HTML reports this build can't produce (no plotters backend), iteration-count and CU figures are consistent everywhere (one auditable derivation: 7,674 × 17 CU).README storefront
Badges (crates.io / docs.rs / CI / license / MSRV), an Installation section (cargo add, feature trimming, MSRV 1.88, re-export policy), a 12-example index with a zero-setup "start here" (
custom_adapter), the Slipstream quoting caveat surfaced beside the Solidly one, and the quickstart now compiles as a doctest (cfg(doctest)README include;rust,ignore→rust,no_run).Tests & benches
u128::MAX/i128limits, Balancer cash at the 2^112 field edges — pinning checked-None(resync) semantics, never wrap/saturate/carry into a co-tenant field.AmmSyncEnginecoverage (was the only protocol with no engine/WS test): aSyncapplies as two exact writes with zero resync work, proven by panicking trace/storage fetchers.benches/reactive_apply.rs(mock-backed cache, pre-warmed packed words — no env, runs in CI): measures every event-sourced apply path end-to-end throughAdapterDriver::apply_log. Measured (July 2026, M-series host): V2Sync~283 ns, Balancer swap ~432 ns (TWO_TOKEN) / ~519 ns (GENERAL), V3 Mint/Burn ~1.4 µs. benchmarks.md's reactive table now carries all five paths instead of extrapolating from the single V2 row.Release mechanics
.cargo/audit.toml:cargo auditis green with the one lockfile-only advisory (RUSTSEC-2025-0055,tracing-subscriber 0.2.25via revm-precompile's optional, never-enabled arkworks backend) ignored with the justification checked in.PoolBalanceManagedsubscription, Algebra forks,Bootstrapper, incremental interests).live.yml: weeklycargo test --all-features -- --ignoredwith theE2E_RPC_URLsecret, plus a cargo-audit job) is ready on a separate branch — the gh token lacksworkflowscope, so it needs an SSH push (see PR comment).#[cfg]attribute in factory.rs, hidingProtocolMetadatafrom solidly-only builds — caught by the isolation clippy matrix, fixed here.Verification
Full battery on a clean tree, all green (22 checks):
cargo fmt --check; clippy-D warningson all-features, no-default, and the 7-way per-protocol isolation matrix (which caught the orphaned-cfg bug above)cargo teston all-features / default / no-default (198 offline tests + the README doctest)-D warningson stable (CI parity) and nightly--cfg docsrs(docs.rs parity — feature badges verified in the rendered HTML)cargo +1.88 check --all-features(MSRV),experimental-protocolsboth bare and stackedcargo audit(green with the checked-in policy), heavy-dep guard,cargo package --list(56 files),cargo publish --dry-runcargo bench --bench reactive_applyruns offline and produced the numbers cited aboveAnd the full live gate against an archive endpoint (
cargo test --all-features -- --ignored): 25/25 passed, 0 failures — per-protocol quote parity (mainnet + Base), factory base-slot/CREATE2 constants, one-shot V3 sync parity, both per-transactionstateDiffwrite-parity suites for the event-sourced paths, and both live WS soaks (~190 s / ~302 s of real mainnet events applied with exact writes).Not in this PR:
live.yml(the scheduled live-test + audit workflow) — the gh token lacksworkflowscope, so it rides the localci/live-testsbranch and needs one SSH push once the 1Password agent behaves. PR #32 (access-list warming) stays deferred to 0.1.x by design.After merge: re-point the
v0.1.0tag at the merge commit (it currently sits six merges behind on6187d50), thencargo publish.🤖 Generated with Claude Code