-
Notifications
You must be signed in to change notification settings - Fork 239
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
TransactionView: Static Account Keys Meta #2410
Conversation
const MAX_STATIC_ACCOUNTS_PER_PACKET: u16 = | ||
(PACKET_DATA_SIZE / core::mem::size_of::<Pubkey>()) as u16; |
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.
Is StaticAccountMeta
going to represent AccountMeta
?
agave/sdk/program/src/instruction.rs
Lines 544 to 551 in 51208f8
pub struct AccountMeta { | |
/// An account's public key. | |
pub pubkey: Pubkey, | |
/// True if an `Instruction` requires a `Transaction` signature matching `pubkey`. | |
pub is_signer: bool, | |
/// True if the account data or metadata may be mutated during program execution. | |
pub is_writable: bool, | |
} |
I was wondering if you should account for the two booleans in addition to the public key.
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 unrelated to that struct. Have just been naming all my internal transaction view structs holding offsets/sizes with Meta
suffixes.
The is_signer
and is_writable
are not part of the actual packet and are implied by combination of account index and information from the header.
So these will be functions on the wrapping transaction_view
once I add the accessor functions.
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 mixed up the names and thought they were related. How about calling the struct StaticAccountKeyMeta
?
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.
a76a7cb
to
b76362e
Compare
Problem
Summary of Changes
Fixes #