-
Notifications
You must be signed in to change notification settings - Fork 784
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
Attach a typed lifetime constraint field when we compile a transaction #2481
Conversation
|
This stack of pull requests is managed by Graphite. Learn more about stacking. Join @mcintyre94 and the rest of your teammates on Graphite |
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.
Looks like you might just be missing something little based on CI, but lgtm!
5a1360b
to
aa8b833
Compare
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 like that this mimics the way it's structured on the TransactionMessage
(but with slightly less information needed at this stage).
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.
🎉 This PR is included in version 1.91.5 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Because there has been no activity on this PR for 14 days since it was merged, it has been automatically locked. Please open a new issue if it requires a follow up. |
This PR adds a typed
lifetimeConstraint
field to the return ofcompileTransaction
, ie to the Transaction object produced by compiling a TransactionMessage. This is required to distinguish between a blockhash and a nonce - the value of these is stored in thelifetimeToken
field (and ultimately serialized) but the type is not.This is required for transaction confirmation which relies on the lifetime constraint to know how to confirm the transaction. Our new Transaction object alone is insufficient for this.
In a future PR I'll need to add code that can take a Transaction and find its lifetime constraint, which will require decoding it and inspecting its first instruction. But in the case where we have an uncompiled TransactionMessage we already know the constraint type and can attach it.