Skip to content
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

Producers support staged tx #961

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft

Conversation

James-Mart
Copy link
Member

No description provided.

@James-Mart James-Mart added the System app Related to system services and their apps/plugins label Dec 13, 2024
@James-Mart James-Mart requested a review from swatanabe December 13, 2024 22:19
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I put this in Transact/ because that's where AuthInterface is defined

@James-Mart James-Mart marked this pull request as draft December 13, 2024 22:24
@James-Mart
Copy link
Member Author

This is in draft because before delivering I need to:

  • Add unit tests - I guess they will have to be in python?
  • Answer some questions:
    • Shouldn't AuthStack be used in checkAuthSys too?
    • Is one AuthStack instance per service sufficient? I think it might be okay to share the same stack between isAuth and isReject, but perhaps need a different stack if this is also added to checkAuthSys...

@swatanabe
Copy link
Collaborator

  • Shouldn't AuthStack be used in checkAuthSys too?

Recursion in account auth doesn't really work with checkAuthSys. Recursion only works with a multisig that allows failure of some nested calls without aborting.

  • Is one AuthStack instance per service sufficient? I think it might be okay to share the same stack between isAuth and isReject, but perhaps need a different stack if this is also added to checkAuthSys...

Technically what we want is one auth stack per top-level call. Actually, I think the easiest way to get fully correct semantics is to pass the stack as a parameter. An auth service that delegates would need to add the current account to the stack before the nested calls. Non-delegating auth services can safely leave off the extra parameter, and the extra data will be ignored. The extra size will not be a problem, because the wasm stack will overflow first (I think the current limit is 255 recursive actions).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
System app Related to system services and their apps/plugins
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants