feat: sync cache invalidation oracle#21459
Conversation
| @@ -106,9 +104,6 @@ describe('e2e_offchain_payment', () => { | |||
| ]) | |||
| .simulate({ from: bob }); | |||
|
|
|||
There was a problem hiding this comment.
This didn't have a TODO, but Claude deleted it and the test still passes. Should I put it back?
There was a problem hiding this comment.
No, the entire point of this PR was to be able to remove these two lines.
There was a problem hiding this comment.
Note that, as stated above, as soon as we add the balance check for Alice (which was blocked by scoped capsules), the forceEmptyBlock will still be necessary unless we selectively cache by scope and contract address
| args: [], | ||
| returnTypes: [], | ||
| }), | ||
| contractStore.getFunctionCall.mockImplementation((_name, _args, address) => |
There was a problem hiding this comment.
Changed the mock so that it used the address from the param
| @@ -20,12 +20,12 @@ export class ContractSyncService implements StagedStore { | |||
| readonly storeName = 'contract_sync'; | |||
|
|
|||
There was a problem hiding this comment.
The only addition to this file is invalidateContract. The rest was a refactor to make ensureContractSynced more easy to read
| @@ -106,9 +104,6 @@ describe('e2e_offchain_payment', () => { | |||
| ]) | |||
| .simulate({ from: bob }); | |||
|
|
|||
There was a problem hiding this comment.
No, the entire point of this PR was to be able to remove these two lines.
Co-authored-by: Nicolás Venturo <nicolas.venturo@gmail.com>
…ontract-sync-cache-invalidation # Conflicts: # yarn-project/pxe/src/contract_function_simulator/oracle/interfaces.ts
…ontract-sync-cache-invalidation # Conflicts: # yarn-project/pxe/src/oracle_version.ts
|
❌ Failed to cherry-pick to |
Cherry-pick of 68e4332 with conflict markers preserved for review. Conflicts in: - yarn-project/pxe/src/contract_function_simulator/oracle/utility_execution.test.ts - yarn-project/pxe/src/oracle_version.ts
Cherry-pick of 68e4332 with conflict markers preserved for review. Conflicts in: - yarn-project/pxe/src/contract_function_simulator/oracle/utility_execution.test.ts - yarn-project/pxe/src/oracle_version.ts
BEGIN_COMMIT_OVERRIDE feat: sync cache invalidation oracle (#21459) END_COMMIT_OVERRIDE
BEGIN_COMMIT_OVERRIDE feat: entrypoint replay protection (#21649) feat: guard BoundedVec oracle returns against dirty trailing storage (#21589) fix: add bounds when allocating arrays in deserialization (#21622) feat: implement manual Packable for structs with sub-Field members (#21576) fix(aztec-node): throw on existing nullifier in getLowNullifierMembershipWitness (#21472) fix: use trait dispatch for array Packable::unpack in card_game_contract (#21683) fix(p2p): penalize peers for errors during response reading (#21680) fix: update nullifier non-inclusion test expectations after early oracle throw (backport #21600) (#21615) fix(aztec-nr): fix OOB index with nonzero offset (#21613) fix(builder): persist contractsDB across blocks within a checkpoint (#21520) fix(stdlib): accept null return_type for void Noir functions (#21647) feat: gas estimations on send (#21646) fix(validator): process block proposals from own validator keys in HA setups (backport #21603) (#21659) fix(p2p): penalize peer on tx rejected by pool (#21677) fix(sequencer): fix checkpoint budget redistribution for multi-block slots (#21692) feat: sync cache invalidation oracle (backport #21459) (#21730) feat!: make AES128 decrypt oracle return Option (backport #21696) (#21735) feat!: include init_hash in private initialization nullifier (backport #21427) (#21736) fix(sequencer): extract gas and blob configs from valid requests only (A-677) (#21747) chore: backport #21744 — replace dead BOOTSTRAP_TO env var with bootstrap.sh build arg (#21748) refactor: revert remove assert_bounded_vec_trimmed (#21758) END_COMMIT_OVERRIDE
Summary
invalidateContractSyncCacheoracle that lets Noir contracts invalidate the PXE's sync cache for a specific contract, forcing re-sync on the next queryregisterSenderso newly registered sender's tagged logs are discovered immediatelyFixes F-414