feat: update bindings for noir-rs v1.0.0-beta.19 - #1
Conversation
- Regenerate uniffi mopro.kt (contract version 29 -> 30, new function checksums) and jniLibs (libmopro_example_app_noir.so + libc++_shared.so for arm64-v8a and x86_64) from mopro-example-app-noir at noir-rs v1.0.0-beta.19, built with the mopro CLI (from main, post-#705) so the barretenberg Android fix (BB_LIB_DIR + Zig) is applied. libjnidispatch.so (JNA) kept as-is. - README: bump the dependency example to v1.0.0-beta.19. Both .so verified free of undefined glibc/__cxx11 symbols; bionic deps only. Publish by pushing a v1.0.0-beta.19 tag (JitPack builds the AAR). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The androidTest was a mopro-template leftover exercising generateCircomProof against a Circom .zkey — but NoirKotlin wraps the Noir-only mopro-example-app-noir crate, where Circom/Halo2 are non-functional stubs. Replace it with getNoirVerificationKey -> generateNoirProof -> verifyNoirProof over the beta.19 noir_multiplier2 fixtures, and bundle those fixtures under androidTest/assets. Validated on an API 36 (arm64) emulator: OK (1 test). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Warning Review limit reached
More reviews will be available in 39 minutes and 24 seconds. Learn how PR review limits work. To continue reviewing without waiting, enable usage-based billing in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits. 🚦 How do rate limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan refill rate. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, the refill rate gradually slows as usage increases. The highest same-day bursts are limited more strictly. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe PR updates the README JitPack dependency to ChangesNoir Test Migration and README Version Bump
UniFFI Kotlin Binding Regeneration
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
lib/src/main/kotlin/uniffi/mopro/mopro.kt (1)
254-256:⚠️ Potential issue | 🟡 Minor | ⚡ Quick winMinor: String interpolation may not work as intended.
Line 255 uses
$status.codewhich interpolatesstatusand then appends.codeas literal text. Should be${status.code}to interpolate the code field.- throw InternalException("Unknown rust call status: $status.code") + throw InternalException("Unknown rust call status: ${status.code}")This is a minor issue since this branch should rarely be hit (only for unknown status codes from Rust).
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@lib/src/main/kotlin/uniffi/mopro/mopro.kt` around lines 254 - 256, The string interpolation in the InternalException message uses incorrect syntax. The expression `$status.code` only interpolates the `status` variable and appends `.code` as literal text instead of accessing the code field. Fix this by wrapping the property access in curly braces to change `$status.code` to `${status.code}` so that the code field value is properly interpolated into the error message.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In `@lib/src/main/kotlin/uniffi/mopro/mopro.kt`:
- Around line 254-256: The string interpolation in the InternalException message
uses incorrect syntax. The expression `$status.code` only interpolates the
`status` variable and appends `.code` as literal text instead of accessing the
code field. Fix this by wrapping the property access in curly braces to change
`$status.code` to `${status.code}` so that the code field value is properly
interpolated into the error message.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: 523c0be0-e63e-4be7-acd0-e3d09059092e
⛔ Files ignored due to path filters (4)
lib/src/main/jniLibs/arm64-v8a/libc++_shared.sois excluded by!**/*.solib/src/main/jniLibs/arm64-v8a/libmopro_example_app_noir.sois excluded by!**/*.solib/src/main/jniLibs/x86_64/libc++_shared.sois excluded by!**/*.solib/src/main/jniLibs/x86_64/libmopro_example_app_noir.sois excluded by!**/*.so
📒 Files selected for processing (5)
README.mdlib/src/androidTest/assets/noir_multiplier2.jsonlib/src/androidTest/assets/noir_multiplier2.srslib/src/androidTest/kotlin/com/github/zkmopro/MoproTest.ktlib/src/main/kotlin/uniffi/mopro/mopro.kt
Condense the 3-line narrative into one line. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Summary
Update NoirKotlin to noir-rs
v1.0.0-beta.19. Downstream counterpart of zkmopro/mopro#705 (tracked under zkmopro/mopro#704), which adopted noir-rs beta.19 + the officialbarretenberg-rs 4.2.0-aztecnr-rc.2and a new Zig/BB_LIB_DIRAndroid build path, but left the wrapper repos to their own repos.Changes
main, post-#705):libmopro_example_app_noir.soandlibc++_shared.soforarm64-v8aandx86_64;libjnidispatch.so(JNA) kept as-is.uniffi/mopro/mopro.ktregenerated (uniffi contract version 30).getNoirVerificationKey → generateNoirProof → verifyNoirProofflow against the beta.19 fixtures.v1.0.0-beta.8 → v1.0.0-beta.19.Verification
./gradlew assemble→ BUILD SUCCESSFUL.After merge, tag
v1.0.0-beta.19for JitPack distribution.Refs: zkmopro/mopro#705, zkmopro/mopro#704
Summary by CodeRabbit
Release Notes
Chores
Tests
Refactor