-
Notifications
You must be signed in to change notification settings - Fork 618
feat: FactStore #23989
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
feat: FactStore #23989
Changes from all commits
Commits
Show all changes
97 commits
Select commit
Hold shift + click to select a range
50d1bf9
feat: richer EphemeralArray and TransientArray APIs
mverzilli fe86aae
refactor: unify EphemeralArray and TransientArray over OracleArray
mverzilli f751057
refactor: share OracleArray test bodies across backends
mverzilli 0b346bf
feat: empty_at for transient arrays
mverzilli 0f9f79f
feat: store/load/delete for ephemeral arrays, symmetric array APIs
mverzilli c4857f9
refactor: generate per-backend OracleArray tests with a comptime macro
mverzilli 7413220
refactor: single parameterized oracle_array_tests macro
mverzilli d49fc3f
refactor: should_fail_ prefix for failing oracle array checks
mverzilli eb07d6c
Merge branch 'merge-train/fairies-v5' into martin/richer-ephemeral-an…
mverzilli 7845f7b
refactor(aztec-nr): rename oracle::ephemeral module to ephemeral_oracles
mverzilli b5948b0
refactor(aztec-nr): rename oracle::transient module to transient_oracles
mverzilli 62ad854
refactor(aztec-nr): rename OracleArray struct to UnconstrainedArray
mverzilli e8ad51f
refactor(aztec-nr): rename oracle_array module to unconstrained_array
mverzilli 91772da
docs(aztec-nr): reflow doc comments orphaned by the UnconstrainedArra…
mverzilli 15a7e00
refactor(aztec-nr): pluralize ArrayOracles, EphemeralOracles, Transie…
mverzilli aa90beb
docs(aztec-nr): restore ArrayOracles trait doc paragraph
mverzilli e174bce
properly document panics
mverzilli 950a4a2
empty does not need to clear
mverzilli c85569f
make find short-circuit
mverzilli 0ca93c6
remove read_as for now
mverzilli 5fac01b
move Serialize/Deserialize traits from UnconstrainedArray
mverzilli f7cbb01
refactor kv functions
mverzilli 1523392
commit missing file
mverzilli 788bd2f
refactor test helpers
mverzilli 51d06cb
another one
mverzilli 261face
tighten access
mverzilli 8e9e6ee
remove excess comments
mverzilli 6f881e0
Merge branch 'merge-train/fairies-v5' into martin/richer-ephemeral-an…
mverzilli 3275759
fix(aztec-nr): iterate for_each forward in UnconstrainedArray and Cap…
mverzilli 981a212
refactor(aztec-nr): use for_each to build log retrieval requests
mverzilli 025cdb8
remove unneeded comment
mverzilli 02a1080
Update migration_notes.md
mverzilli b2794c7
fix(aztec-nr): defer pending partial note removal until iteration is …
mverzilli 61030ca
refactor(aztec-nr): process partial note completion logs in a backwar…
mverzilli 84ea55b
Merge branch 'merge-train/fairies-v5' into martin/f-729-fix-array-for…
mverzilli 3766597
feat(pxe): EntityStore for entity-scoped fact storage
mverzilli 1918471
feat(pxe): prune retractable entity facts on chain prune
mverzilli a1752cd
test(pxe): cover retractable entity prune in the synchronizer test
mverzilli eea00a0
refactor(pxe): rename entity store anchor to origin block
mverzilli 753c09f
refactor(pxe): split StoredFact and StoredEntity into separate files
mverzilli e43ca83
add type aliases for readability
mverzilli b4d85e7
refactor
mverzilli f740bbf
more test coverage
mverzilli f41a8ab
renames
mverzilli 9c546af
more refactors
mverzilli 9fc3d50
make entity and fact creation idempotent instead of overwriting
mverzilli 6b638e9
refactor
mverzilli 4a8a441
refactor
mverzilli db2fb8b
more refactors
mverzilli 7b40aa2
and more refactors
mverzilli 19b6079
stronger write checks
mverzilli 50b2a2f
more refactors
mverzilli bfbd60e
another refactor
mverzilli 1c8cd73
tweak
mverzilli 1d639bf
refactor
mverzilli fe78892
more refactors
mverzilli c59658e
rename files
mverzilli aeefa59
move types
mverzilli 58f44d5
clean up stored_entity
mverzilli 5a51955
simplify stored fact module
mverzilli e3843bc
comment cleanup
mverzilli cd75caa
use random values instead of hand-picked ones in tests
mverzilli 476272f
sanitize tests
mverzilli 9a2db88
fix ci
mverzilli e85a246
Merge branch 'merge-train/fairies-v5' into martin/f-729-fix-array-for…
mverzilli 40d0613
Merge branch 'martin/f-729-fix-array-for-each' into martin/entity-store
mverzilli 6c73766
Merge branch 'merge-train/fairies-v5' into martin/entity-store
mverzilli e82f03f
make entity creation idempotent
mverzilli fed3132
make blocksynchronizer ivars readonly
mverzilli 1b4b0ab
simplify test description
mverzilli a328b40
commitRecord->commitFact
mverzilli 63e6561
rename internal staged ops
mverzilli b560096
bifurcate block synchronizer prune test
mverzilli fddc199
add doesEntityExist
mverzilli bf3906b
idb hardening
mverzilli f550dce
enhance block synchronizer tests
mverzilli 7547439
further explain entity store
mverzilli 7568955
address code review feedback
mverzilli 13fd6a8
more test coverage
mverzilli b4a1105
extract deleteFact
mverzilli 1f39d9d
change stored entity encoding
mverzilli fe234b3
add logs for defensive cases
mverzilli 0d27ad2
minor tweak
mverzilli b3a2331
linter
mverzilli c34c755
Merge branch 'merge-train/fairies-v5' into martin/entity-store
mverzilli 391f21e
fix ci
mverzilli 33b95b5
wip
mverzilli 1600151
refactor entity -> fact collection
mverzilli c5563e7
more robust for idb
mverzilli d99df2b
tweaks
mverzilli 231ca47
refactor(pxe): encode scope in fact collection keys
mverzilli 17402d4
refactor(pxe): isolate fact collections by scope in the store
mverzilli 712a7d2
test(pxe): update block synchronizer fact tests for scope-in-key
mverzilli 273344c
test(pxe): regenerate fact store schema snapshots for scope-in-key (P…
mverzilli b935e93
docs(pxe): correct stale fact store JSDoc after scope-isolation refactor
mverzilli 9e7ef97
trim comments
mverzilli cab7fb1
final touches
mverzilli File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
208 changes: 188 additions & 20 deletions
208
yarn-project/pxe/src/block_synchronizer/block_synchronizer.test.ts
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
40 changes: 40 additions & 0 deletions
40
yarn-project/pxe/src/storage/backwards_compatibility_tests/__snapshots__/FactStore.json
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| { | ||
| "facts": [ | ||
| { | ||
| "key": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000aa:0x0000000000000000000000000000000000000000000000000000000000000003:0x00eebee6df09ad503384e049aea9fbf0c0db2f5af46673e550694c6564d973f7:6:0x0000000000000000000000000000000000000000000000000000000000000002", | ||
| "value": "00000000000000000000000000000000000000000000000000000000000000640000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000700000000000000000000000000000000000000000000000000000000000000aa000000000000000000000000000000000000000000000000000000000000000300000001000000000000000000000000000000000000000000000000000000000000000501000000060000000000000000000000000000000000000000000000000000000000000002" | ||
| }, | ||
| { | ||
| "key": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb:0x0000000000000000000000000000000000000000000000000000000000000001:0x00a802572c436574f713d43f1852859f4496d694de0e5b17b89cf983439e6143:none", | ||
| "value": "00000000000000000000000000000000000000000000000000000000000000640000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000700000000000000000000000000000000000000000000000000000000000000bb000000000000000000000000000000000000000000000000000000000000000100000001000000000000000000000000000000000000000000000000000000000000000900000000000000000000000000000000000000000000000000000000000000000000000000" | ||
| }, | ||
| { | ||
| "key": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb:0x0000000000000000000000000000000000000000000000000000000000000002:0x00df3f619804a92fdb4057192dc43dd748ea778adc52bc498ce80524c014b811:5:0x0000000000000000000000000000000000000000000000000000000000000001", | ||
| "value": "00000000000000000000000000000000000000000000000000000000000000640000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000700000000000000000000000000000000000000000000000000000000000000bb00000000000000000000000000000000000000000000000000000000000000020000000001000000050000000000000000000000000000000000000000000000000000000000000001" | ||
| } | ||
| ], | ||
| "facts_by_collection": [ | ||
| { | ||
| "key": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000aa", | ||
| "value": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000aa:0x0000000000000000000000000000000000000000000000000000000000000003:0x00eebee6df09ad503384e049aea9fbf0c0db2f5af46673e550694c6564d973f7:6:0x0000000000000000000000000000000000000000000000000000000000000002" | ||
| }, | ||
| { | ||
| "key": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb", | ||
| "value": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb:0x0000000000000000000000000000000000000000000000000000000000000001:0x00a802572c436574f713d43f1852859f4496d694de0e5b17b89cf983439e6143:none" | ||
| }, | ||
| { | ||
| "key": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb", | ||
| "value": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb:0x0000000000000000000000000000000000000000000000000000000000000002:0x00df3f619804a92fdb4057192dc43dd748ea778adc52bc498ce80524c014b811:5:0x0000000000000000000000000000000000000000000000000000000000000001" | ||
| } | ||
| ], | ||
| "facts_by_block": [ | ||
| { | ||
| "key": "num:5", | ||
| "value": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000bb:0x0000000000000000000000000000000000000000000000000000000000000002:0x00df3f619804a92fdb4057192dc43dd748ea778adc52bc498ce80524c014b811:5:0x0000000000000000000000000000000000000000000000000000000000000001" | ||
| }, | ||
| { | ||
| "key": "num:6", | ||
| "value": "utf8:0x0000000000000000000000000000000000000000000000000000000000000064:0x0000000000000000000000000000000000000000000000000000000000000001:0x0000000000000000000000000000000000000000000000000000000000000007:0x00000000000000000000000000000000000000000000000000000000000000aa:0x0000000000000000000000000000000000000000000000000000000000000003:0x00eebee6df09ad503384e049aea9fbf0c0db2f5af46673e550694c6564d973f7:6:0x0000000000000000000000000000000000000000000000000000000000000002" | ||
| } | ||
| ] | ||
| } |
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.