Conversation
PR SummaryMedium Risk Overview
On the server, Written by Cursor Bugbot for commit dbd779f. This will update automatically on new commits. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
| TransactionStatus::PreconfirmationSuccess(PreconfirmationSuccessStatus { | ||
| tx_id, | ||
| status, | ||
| time: Tai64::now(), |
There was a problem hiding this comment.
Preconfirmation time uses Tai64::now() instead of actual timestamp
High Severity
The time field for PreconfirmationSuccessStatus and PreconfirmationFailureStatus is set to Tai64::now() inside TransactionStatus::new(). This means every time a preconfirmation status is constructed — including when retrieved from storage via a query — the timestamp reflects the current wall-clock time, not when the preconfirmation actually occurred. Normal SuccessStatus and FailureStatus correctly use self.status.block_timestamp from persisted data, but the underlying PreConfirmationSuccess/PreConfirmationFailure structs lack a timestamp field entirely, so Tai64::now() was used as a stand-in. This yields non-deterministic, incorrect timestamps on repeated queries.


Linked Issues/PRs
#3160
Description
Checklist
Before requesting review
After merging, notify other teams
[Add or remove entries as needed]