Skip to content

fix(pxe): only skip sync for stub overrides, not on-chain class overrides#23016

Closed
dbanks12 wants to merge 1 commit into
db/private-sim-contract-overridesfrom
db/sync-stub-overrides-only
Closed

fix(pxe): only skip sync for stub overrides, not on-chain class overrides#23016
dbanks12 wants to merge 1 commit into
db/private-sim-contract-overridesfrom
db/sync-stub-overrides-only

Conversation

@dbanks12
Copy link
Copy Markdown
Contributor

@dbanks12 dbanks12 commented May 7, 2026

Summary

PXE skips sync for any contract that appears in SimulationOverrides.contracts. The skip was added to defend against a hostile no-op sync_state in account stubs (simulated_*_account_contract); without it, sync would trigger their assert(false). The blanket skip is too coarse: it also blocks pre-existing notes from being loaded for real contract overrides (e.g. fastForwardContractUpdate), causing private calls that read prior state to fail with "Failed to get a note".

Fix

Narrow the skip to overrides whose class id isn't published on chain. On-chain classes have full artifacts and need sync (upgrade-sim flow). Off-chain-only classes (account stubs registered via pxe.registerContractClass) keep being skipped — the existing behavior they need.

Test plan

  • e2e_kernelless_simulation (account stub overrides): 7/7 pass
  • e2e_contract_updates (upgrade-sim via fastForwardContractUpdate, including the new private-dispatch test upstack): 6/6 pass

Copy link
Copy Markdown
Contributor Author

dbanks12 commented May 7, 2026

@dbanks12 dbanks12 force-pushed the db/private-sim-contract-overrides branch from c6a9a2a to dcc944a Compare May 7, 2026 14:41
@dbanks12 dbanks12 force-pushed the db/sync-stub-overrides-only branch 2 times, most recently from 028f86a to ff6e112 Compare May 7, 2026 14:44
@dbanks12 dbanks12 force-pushed the db/private-sim-contract-overrides branch from dcc944a to 9aa157b Compare May 7, 2026 14:44
@dbanks12 dbanks12 marked this pull request as ready for review May 7, 2026 14:44
@dbanks12 dbanks12 force-pushed the db/private-sim-contract-overrides branch from 9aa157b to 713e7c5 Compare May 7, 2026 18:43
@dbanks12 dbanks12 force-pushed the db/sync-stub-overrides-only branch 2 times, most recently from 380d41b to f9579f0 Compare May 8, 2026 00:55
@dbanks12 dbanks12 force-pushed the db/private-sim-contract-overrides branch from 713e7c5 to b5280d2 Compare May 8, 2026 00:55
@dbanks12 dbanks12 force-pushed the db/sync-stub-overrides-only branch from f9579f0 to e8ea379 Compare May 8, 2026 00:55
@dbanks12 dbanks12 force-pushed the db/private-sim-contract-overrides branch from b5280d2 to 14c427f Compare May 8, 2026 00:55
@dbanks12 dbanks12 closed this May 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant