-
Notifications
You must be signed in to change notification settings - Fork 234
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Broadcasting unconstrained function with empty sibling (#5429)
We were accidentally removing zero elements from the beginning of the sibling path when broadcasting unconstrained functions. Looking at the [logs from failed runs](https://app.circleci.com/pipelines/github/AztecProtocol/aztec-packages/30898/workflows/4010907e-6c6c-41f7-bcc1-48e886fb30cb/jobs/1462699/parallel-runs/0), it seems to be the culprit: ``` 2024-03-25 14:15:00 sandbox_1 | aztec:circuits:artifact_hash TRACE Computed artifact hash artifactHash=0x05ec36f43999f40c957a0ed86659191680430fc1c9f2c451a1cfea8b71f0d7e0 privateFunctionRoot=0x2183eee0e130f895c25e3cda8b7f3b367baeb0bca0ddf5689ac6979da1e8cdb0 unconstrainedFunctionRoot=0x2b65d4d40fae120ec8738725cec71ffb4e340d1a17f678e7b03c1ab05e646210 metadataHash=0x229d43c7daac528d0aefd72bee59385d7e9ff06ea477b673389e1f65168cba9f +0ms 2024-03-25 14:15:17 end-to-end_1 | aztec:circuits:function_membership_proof TRACE Computed proof for unconstrained function with selector 0xcff0a264 functionArtifactHash=0x26d3bd465a183b367291552b08bd192043bebb5d7b07b6f8b7d43432d74af09b functionMetadataHash=0x1a8b89c75f0ad79c19ba53a8bdfcb25bd4f8d33bfa11f1f52528a8ee58fc2543 artifactMetadataHash=0x229d43c7daac528d0aefd72bee59385d7e9ff06ea477b673389e1f65168cba9f artifactFunctionTreeSiblingPath=0x0000000000000000000000000000000000000000000000000000000000000000,0x01c398cebbd80cad3c89750c7523a853883c54d2248d7f5c634b50b1cf282422 privateFunctionsArtifactTreeRoot=0x2183eee0e130f895c25e3cda8b7f3b367baeb0bca0ddf5689ac6979da1e8cdb0 +0ms 2024-03-25 14:15:23 sandbox_1 | aztec:circuits:function_membership_proof TRACE Artifact hash mismatch expected=0x05ec36f43999f40c957a0ed86659191680430fc1c9f2c451a1cfea8b71f0d7e0 computedArtifactHash=0x16fcaee22ed912eb011b05ec01cc8bb34a189fe162f122918cc1aa141ec3cc77 computedFunctionArtifactHash=0x26d3bd465a183b367291552b08bd192043bebb5d7b07b6f8b7d43432d74af09b computedArtifactFunctionTreeRoot=0x22266dee73fdd82ff937cd96df83d2d3f96a833978c639289146aa82eceaf305 privateFunctionsArtifactTreeRoot=0x2183eee0e130f895c25e3cda8b7f3b367baeb0bca0ddf5689ac6979da1e8cdb0 metadataHash=0x229d43c7daac528d0aefd72bee59385d7e9ff06ea477b673389e1f65168cba9f artifactFunctionTreeSiblingPath=0x01c398cebbd80cad3c89750c7523a853883c54d2248d7f5c634b50b1cf282422 +0ms ``` Note how the `artifactFunctionTreeSiblingPath` starts with a zero when computing the proof, but that's missing when verifying it.
- Loading branch information
1 parent
13a12d5
commit 933145e
Showing
11 changed files
with
96 additions
and
15 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
4 changes: 2 additions & 2 deletions
4
yarn-project/circuits.js/src/contract/public_bytecode.test.ts
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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