fix: support millisecond quote stamps in simulations - #4880
Draft
6heLL66 wants to merge 1 commit into
Draft
Conversation
|
I have read the CLA Document and I hereby sign the CLA You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot. |
6heLL66
force-pushed
the
fix/metric-oracle-restamping
branch
2 times, most recently
from
September 9, 2026 12:09
79395d4 to
eb452eb
Compare
6heLL66
force-pushed
the
fix/metric-oracle-restamping
branch
from
September 9, 2026 13:15
eb452eb to
1cb2f81
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Titan quotes can contain uint48 millisecond timestamps at bytes 25..31, as in the captured Metric quote below. The stream currently recognizes only leading uint32 seconds, so these quotes retain the builder's future timestamp and can revert when simulated at the parent block.
Recognize the millisecond layout by an exact match to its frame's projected timestamp, independently of oracle or venue addresses. Each format selects its newest timestamp separately: a newer millisecond quote cannot change which seconds quotes are restamped. The original seconds recognition, maximum selection and restamping body are preserved.
Track millisecond eligibility per winning account, slot and storage field, so overwritten or unrecognized frames cannot borrow freshness. Seconds-format matches retain priority, including dual-format words that later become stale. Millisecond timestamps are never moved forward; all other bytes and account fields are preserved. Both
stateandstateDiffare supported, with no public API or configuration changes.For the captured quote targeting block 25,925,280, simulating at its parent changes
01a07bb2de38(1788781715000 ms) to01a07bb2af58(1788781703000 ms). The remaining 26 bytes stay identical.Draft proposal following the contribution guide; follow-up to #4691.
Validation
No new tests are included in the final diff. Existing test fixtures and calls only receive the metadata/signature adjustments required by the implementation.
1cb2f81e3, with four additional regressions kept in the validation branch: 23 simulator tests passed, 8 external-service/replay tests skipped. Clippy passed for all simulator features and targets with-D warnings(existing unreachable-Alloy-path configuration warnings remain).The skipped external-service/replay tests remain unverified; the in-process websocket/reconnect test passed in CI.