-
Notifications
You must be signed in to change notification settings - Fork 3.6k
feat: L2ToL2CDM SentMessage originContext #15844
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
feat: L2ToL2CDM SentMessage originContext #15844
Conversation
l2tol2cdm.sentmessage.ctx
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #15844 +/- ##
===========================================
- Coverage 46.86% 45.99% -0.87%
===========================================
Files 1338 1283 -55
Lines 108127 103891 -4236
===========================================
- Hits 50672 47788 -2884
+ Misses 53847 52630 -1217
+ Partials 3608 3473 -135
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
@@ -55,17 +55,12 @@ contract L2ToL2CrossDomainMessenger is ISemver, TransientReentrancyAware { | |||
bytes32 internal constant CROSS_DOMAIN_MESSAGE_SOURCE_SLOT = | |||
0x711dfa3259c842fffc17d6e1f1e0fc5927756133a2345ca56b4cb8178589fee7; | |||
|
|||
/// @notice Event selector for the SentMessage event. Will be removed in favor of reading |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no longer needed with the merged bugfix
/// @return Hash of the encoded message parameters, used to uniquely identify the message. | ||
function hashL2toL2CrossDomainMessage( | ||
uint256 _destination, | ||
uint256 _source, | ||
uint256 _nonce, | ||
address _sender, | ||
address _target, | ||
bytes memory _message | ||
bytes memory _message, | ||
bytes memory _context |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
critical to include here so that resendMessage
works as intended
@@ -16,7 +16,7 @@ import { ISuperchainTokenBridge } from "interfaces/L2/ISuperchainTokenBridge.sol | |||
/// @notice Integration test that checks that the `ExecutingMessage` event is emitted on crosschain mints. | |||
contract ExecutingMessageEmittedTest is CommonTest { | |||
bytes32 internal constant SENT_MESSAGE_EVENT_SELECTOR = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use the selector property on the event itself rather than hardcoding it and needing it to change?
@@ -145,19 +146,22 @@ contract L2ToL2CrossDomainMessenger is ISemver, TransientReentrancyAware { | |||
if (_target == Predeploys.L2_TO_L2_CROSS_DOMAIN_MESSENGER) revert MessageTargetL2ToL2CrossDomainMessenger(); | |||
|
|||
uint256 nonce = messageNonce(); | |||
bytes memory context = ""; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am confused, should there be a sendMessage(uint,address,bytes,bytes)
in addition where the context can be set?
Can you link the specs PR to this PR? edit: I see ethereum-optimism/specs#700 |
This pr has been automatically marked as stale and will be closed in 5 days if no updates |
Closing in favor of #16150 |
Implementation of Design Doc.