-
Notifications
You must be signed in to change notification settings - Fork 210
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
Can't specify arbitrary foreign accounts for method call #732
Comments
Looks like there is an intent. This will lead to a bloated interface (my app has 3 addresses in state, used in many methods), but, well, if rules say so, I'll rewrite it. But, I'm curious – why py-SDK allows it then? It's really misleading, when same SDK behaves differently in different languages. |
Once this is merged #725 you'll be able to do this. Alternatively you could specify that the Address is of type Account instead, this would make the sdk machinery work as it is right now, but that might conflict with some already deployed contract? |
@barnjamin My app is not released yet, so any experiments are ok. But I don't see how changing param type can help here, could you please explain it a bit? And, as #725 is merged yesterday, when it is expected to be released? |
The pr allows you to specify arbitrary accounts that are not included in the method signature of the ABI method. Once its tagged and released, Until then an alternative for this specific instance would be for you to change the method signature of |
In a simplified way, my contract has following logic:
To make it work,
addressee
value must be explicitly submitted inaccounts
application array.In python it works fine:
In JS it doesn't:
Which is because in JS SDK
accounts
field is composed internally, based on method args only. WhileappAccounts
field is not used at all, despite it's declared as a validTransactionOverrides
parameter.I can construct txn manually, using
makeApplicationCallTxn
directly.But can't use ATC – and thus can't use beaker-ts
ApplicationClient
- with all the handy stuff it provides.Is this a bug or there is some intent here?
The text was updated successfully, but these errors were encountered: