-
Notifications
You must be signed in to change notification settings - Fork 106
feat: remove asset_witnesses field from TransactionInputs #2274
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
Conversation
950514f to
74af7e5
Compare
PhilippGackstatter
left a comment
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 good to me!
I left some small comments about the structure, but directionally this looks great.
74af7e5 to
187297f
Compare
Address review feedback: - Keep asset_witnesses field in TransactionInputs (revert removal) - Refactor with_asset_witnesses() to use TransactionAdviceInputs::add_asset_witness() - Restore data extractor methods (read_storage_map_witness, etc.) - Add explicit error handling for non-fungible fee assets - Make account_id_map_key() public in TransactionAdviceInputs Closes 0xMiden#2261
187297f to
238c044
Compare
PhilippGackstatter
left a comment
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.
Thanks for the updates! I left one comment that may be difficult to address, but I hope it's clear enough. Let me know if you need help.
476bd07 to
4c4e5e5
Compare
Thank you for detailed guide. I handled all @PhilippGackstatter . needs review. let me know if anything I missed :) |
PhilippGackstatter
left a comment
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.
Thank you! I think we're pretty close now 😃
4c4e5e5 to
fd1087a
Compare
@PhilippGackstatter now all must be okay. still I'm ready to change if you need anything else 😅 |
fd1087a to
8a79662
Compare
PhilippGackstatter
left a comment
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 good to me! Thanks for your work, and apologies for the back and forth. There's one issue that's causing the test failures - left a comment.
| // Copy the tx_args advice inputs to self.advice_inputs first, so that any data | ||
| // from a previous execution (e.g., during re-execution) is preserved. | ||
| self.advice_inputs.extend(tx_args.advice_inputs().clone()); |
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'm not exactly sure why, but this line cause the test failures, e.g. in test_nested_fpi_native_account_invocation. Let's revert this.
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 good to me! Thanks for your work, and apologies for the back and forth. There's one issue that's causing the test failures - left a comment.
No problem at all. I like work for Miden fun and educational :)
will handle now
| /// Pre-fetched asset witnesses for note assets and the fee asset. | ||
| asset_witnesses: Vec<AssetWitness>, |
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.
Wasn't one of the objects to remove the asset_witnesses fields from TransactionInputs?
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 created #2298 as an alternative.
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.
what should I do now @bobbinth .. wait ? :)
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.
Let's get some feedback from @PhilippGackstatter. Depending on that, we can decide which approach to take.
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.
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 think these PRs are mostly doing the same now, but #2298 handles the initial fee balance in a less intrusive way and avoids the need for
PreparedTransactionInputs, so I think that's the better way to go. Thank you for providing a basis to work from @Farukest!
Hi @PhilippGackstatter, @bobbinth should I close #2274 since this one is moving forward ? Also, would appreciate a co-author tag if possible. Thanks in advance :)
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.
Yes, I'll close this now. Thank you for your help on this! I added the co-author tag - hopefully, it worked as intended.
2b424e5 to
3c67348
Compare
|
Superseded by #2298. |
Summary
Removes the
asset_witnessesfield fromTransactionInputsstruct.Changes
asset_witnessesfield fromTransactionInputs- witnesses are now added directly toadvice_inputsviawith_asset_witnesses()prepare_tx_inputsto return(TransactionInputs, u64)tuplenotes_checkerfor new signatureCloses #2261