Strip deploy + Rust/npm surface: the library half is Solidity only - #263
Conversation
Per rain.math.float#262 (Split into library + rain.math.float.deploy) and the
Hard Case A ruling, this repo becomes the pure Solidity math library that
publishes only the `rain-math-float` Soldeer package. The deployed concrete,
deploy pins/snapshot, deploy scripts/tests, and the Rust/WASM/npm bindings move
to rain.math.float.deploy.
Removed (77 files):
- Deploy Solidity: src/concrete/DecimalFloat.sol, src/generated/*,
src/lib/deploy/LibDecimalFloatDeploy.sol, script/{Deploy,BuildPointers,
check-published-deploy-constants.sh}, deploy tests, LibLogTable.bytes.t.sol.
- Rust/npm: crates/**, Cargo.*, package*.json, tsconfig.json, .prettierignore,
test_js/**, scripts/*.js, the CopyArtifacts bridge (script + lib + test),
and TestDecimalFloat harness + its two wrapper tests.
- Workflows: copy-artifacts, manual-sol-artifacts, rainix-rs-{static,test,wasm}.
Added / changed:
- test/abstract/LogTest.sol rewritten self-contained (Hard Case C): rebuilds the
combined log tables from LibLogTable source and deploys them via LibDataContract
at a `create` address, so the transcendental tests (log10/pow/pow10/sqrt) run
with no Zoltu deploy pin and no src/generated snapshot.
- foundry.toml: drop rain-deploy + rain-sol-codegen deps, [rpc_endpoints],
[etherscan], fs_permissions, ffi. Pragma stays `^`.
- package-release.yaml: publish only the rain-math-float Soldeer package
(drop crate + npm-package inputs).
- flake.nix: drop test-wasm-build + test-js-bindings tasks.
- CLAUDE.md/README/REUSE.toml/.soldeerignore/.gitignore/remappings: library-only.
- .gas-snapshot + soldeer.lock regenerated for the stripped tree.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Warning Review limit reached
Next review available in: 58 minutes Limit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?Wait for the limit to reset, then comment An organization admin can change what happens after included review limits in Billing. How do review limits work?CodeRabbit enforces per-developer PR review limits within each organization. For paid Pro and Pro+ reviews, CodeRabbit uses a developer's included PR review attempts over the past 7 days to set the current hourly allowance. At typical activity levels, the full plan allowance applies. Higher sustained activity can lower the allowance until earlier attempts leave the 7-day window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (4)
📒 Files selected for processing (84)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai assess this PR size classification for the totality of the PR with the following criterias and report it in your comment: S/M/L PR Classification Guidelines:This guide helps classify merged pull requests by effort and complexity rather than just line count. The goal is to assess the difficulty and scope of changes after they have been completed. Small (S)Characteristics:
Review Effort: Would have taken 5-10 minutes Examples:
Medium (M)Characteristics:
Review Effort: Would have taken 15-30 minutes Examples:
Large (L)Characteristics:
Review Effort: Would have taken 45+ minutes Examples:
Additional Factors to ConsiderWhen deciding between sizes, also consider:
Notes:
|
Blocker RESOLVED 2026-08-22:
rain-math-float-deploy0.1.1 is published to Soldeer (releasesol-v0.1.1, run 32572473272). External importers ofLibDecimalFloatDeploynow have the deploy package to move to.Strips the deploy surface and the Rust/npm surface from
rain.math.float, leaving the pure Solidity math library that publishes only therain-math-floatSoldeer package. Executes the plan ruled in #262 (the migration-plan comment + the Hard Case A ruling). The concrete, the rolling deploy machinery, the deploy scripts/tests, and the Rust/WASM/npm bindings now live inrain.math.float.deploy. The LIBRARY-tagged pin records (*_0_1_1:0xBee0eE…C926/0x7a93d031…) are DELETED, not relocated — the deploy repo'ssrc/generated/0_1_1/freezes its own release, a different artifact. Those records survive in this repo's git history and the immutable Soldeer archives; consumers have git.🔒 Blocked-by (ordering constraint)
Must not land until
rain.math.float.deployhas published itsrain-math-float-deploySoldeer package, so external importers ofLibDecimalFloatDeploy/ the deployed addresses have somewhere to repoint. Tracker: rainlanguage/rain.math.float.deploy#1 (step 4 —sol-v*tag → Soldeer publish — is still pending). Source ruling + plan: #262.Repointing other org consumers is out of scope here (2026-08-20 human narrowing).
Removed (77 files)
Deploy Solidity (Tier 1 + Tier 2, un-gated):
src/concrete/DecimalFloat.sol,src/generated/LogTables.pointers.sol,src/lib/deploy/LibDecimalFloatDeploy.solscript/Deploy.sol,script/BuildPointers.sol,script/check-published-deploy-constants.sh,script/lib/LibEtchLogTables.soltest/src/concrete/*.t.sol(31),test/src/lib/deploy/*.t.sol(4),test/src/lib/table/LibLogTable.bytes.t.solRust/npm surface + CopyArtifacts bridge:
crates/**(15),Cargo.toml,Cargo.lock,package.json,package-lock.json,tsconfig.json,.prettierignore,test_js/**,scripts/*.jsscript/CopyArtifacts.sol,script/lib/LibCopyArtifacts.sol,test/script/CopyArtifacts.t.soltest/concrete/TestDecimalFloat.sol+ its two wrapper tests (TestDecimalFloat.unpack.t.sol,DecimalFloat.packLossless.t.sol) — per Correction 1; directpackLossless/unpackcoverage stays intest/src/lib/LibDecimalFloat.pack.t.solcopy-artifacts.yaml,manual-sol-artifacts.yaml,rainix-rs-static.yaml,rainix-rs-test.yaml,rainix-rs-wasm.yamlKept
src/lib/{LibDecimalFloat, format, parse, implementation, table/LibLogTable}+src/error/*; its full test suite; the slow reference impls (test/lib/*).rain-datacontractdep (the test log-tables helper needs it).package-release.yaml(now publishes onlyrain-math-floatSoldeer),rainix-sol.yaml,pr-assessment.yaml.Added (Hard Case C — mandatory)
test/abstract/LogTest.solrewritten self-contained: rebuilds the combined log/anti-log tables purely fromLibLogTablesource (toBytesof the five tables +LOG_TABLE_DISAMBIGUATOR, byte-identical to the old frozencombinedTables()), deploys them viaLibDataContractat acreateaddress, and hands the address to the 8 transcendental tests. No Zoltu deploy pin, nosrc/generated.Config edits
foundry.toml: droprain-deploy+rain-sol-codegendeps,[rpc_endpoints],[etherscan],fs_permissions,ffi(no retained test usesvm.ffi). Pragma stays^,optimizer_runsuntouched.flake.nix: droptest-wasm-build+test-js-bindingstasks.remappings.txt/soldeer.lockregenerated (deps:forge-std,@openzeppelin-contracts,rain-solmem,rain-string,rain-datacontract)..gas-snapshotregenerated for the stripped suite;CLAUDE.md/README.md/REUSE.toml/.soldeerignore/.gitignorelibrary-only.CI (green locally,
nix develop -c)forge build→ successfulforge test→ 444 passed, 0 failed, 0 skipped (48 suites); transcendental tests pass on the new helperslither .→ 0 results (14 contracts)reuse lint→ compliant (78/78 files)QA
LogTest.logTables()helper —LibDecimalFloat.{log10,pow,pow10,sqrt}.t.solandLibDecimalFloatImplementation.{internals,log10,lookupLogTableVal,pow10}.t.sol. They fail if the helper deploys the wrong table bytes (transcendental lookupsextcodecopyfrom the tables address; garbage tables give wrong results, and the packed-vs-unpacked and slow-reference cross-checks in these files diverge). Verified: 444 passed / 0 failed / 0 skipped on the stripped tree; before the strip these tests reached the tables via the Zoltu-pinned etch, and they now reach byte-identical tables via the self-contained helper (same 8 tests, same assertions, still green).test/src/lib/table/LibLogTable.bytes.t.solassertedLibLogTable.toBytes(logTableDec()) == LOG_TABLES(and the same for the other four tables) against the frozensrc/generated/LogTables.pointers.solsnapshot — exactly the fivetoBytes(...)terms the new helper concatenates. So the helper's output is provably byte-identical to the oldLibDecimalFloatDeploy.combinedTables()it replaces. Transcendental expected values are additionally cross-checked against the slow reference implementations intest/lib/.rain-datacontract; added = the mandatory Hard Case C helper. No consumer repointing (out of scope per the 2026-08-20 narrowing).Closes the library-strip step of #262 once unblocked.
Adversarial-review disclosures (2026-08-22)
next-v0.2.0is pushed, so autopublish ships itas
rain-math-float 0.2.0, not a patch bump. Consumers importing the removed surface(rainlang's six
src/lib/op/math/*opcodes, raindex's script) stay pinned to theircurrent versions until they deliberately move to
rain-math-float-deploy.mainruleset required six status contexts produced by workflows thisPR deletes (
copy-artifacts,rs-static,rs-test×2,rs-wasm, plus thealready-rotten
build-pointers). The ruleset is being trimmed to the survivingrainix-solcontexts alongside this merge; without that, every post-merge PR needsadmin bypass.
production tables (
LogTest's codehash assertion and the frozen-bytes pin left with thedeploy surface). A table-data change here passes library CI self-consistently and is
caught when the deploy repo bumps its pin. That is the split's intent; stated so it is
not rediscovered as a gap.
and moots fix(deploy): pin the 0.1.7 soldeer tag's deploy constants #256/fix(deploy): pin the 0.1.7 soldeer tag's deploy constants #266/fix(ci): rename the codegen script to script/Build.sol #267 (nowhere left to pin a library tag).