-
Notifications
You must be signed in to change notification settings - Fork 56
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
Improve fee payer txn submission APIs #522
Conversation
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.
Have you seen this PR? following upcoming changes to the framework
#467
I have but is it relevant to this PR? doesn't seem so afaict |
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, seems to miss one condition though.
- signAndSubmitTransaction -> sender: Account, feePayer: Account (1 step sign)
- signAndSubmitTransaction -> sender: Account, feePayer: AccountAuthenticator (2 step sign)
- signAndSubmitAsFeePayer -> sender: AccountAuthenticator, feePayer: Account (2 step sign)
- (Missing) signAndSubmitAsFeePayer -> sender: Account, feePayer: Account (1 step sign)
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.
KeylessAccountCommon seems like the wrong name for that interface, and it's a little weird of functionality here
I figure that this doesn't make sense. If you are submitting as the fee payer you don't have access to the sender account and the sender ought to send you an authenticator that's valid for sponsorship. Additionally the case is covered by the usual signAndSubmitTransaction. |
Description
This simplifies the fee payer APIs by reducing the steps needed to submit such a transaction while still maintaining support for remote signing.
Now the txn may be submitted either on the fee payer side or the sender side.
This also improves the keyless experience as proofs may be fetched asynchronously, in those cases since submission is an async function where we can await the proof fetch.
Test Plan
Tested via sponsored txn example.
More tests in progress
Related Links