-
Notifications
You must be signed in to change notification settings - Fork 758
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
bug: default value doesn't exists as mentioned in docs #773
Comments
I am not sure it says anything about the default value. It says it is undefined or ..., on that point, invokeFunction because of formatSignature does need sig even doe it is optional, this could be the issue referring to? |
Note that Contract interface is : starknet.js/src/contract/interface.ts Line 115 in 8e058fb
and contract/default.ts is : starknet.js/src/contract/default.ts Line 320 in 8e058fb
Return type is not consistent between interface and implementation. Should be corrected ( |
sorry i meant to link this in the issue : https://www.starknetjs.com/docs/API/classes/Provider#invokefunction
yeah that make sense, i think then we just need to update doc saying that its required field. |
@PhilippeR26 starknet doesn't mandate signature, its upto the account contract implementer to decide how to use passed in signature, signature can be avoided altogether (althought that would be very rare) without |
That's why i used the word standard about signature handled by Starknet.js. Today Starknet.js latest version v5.21.0 isn't coded to handle account abstraction about hash and signature. Even if you can use a very low level function to enter with some abstraction, nothing is made for handle all abstraction possibilities at high level. |
And I have some difficulties to see the interest to pay to use a blockchain, using an account that do not provides any safety of a crypto signature. |
there probably isn't a good reason for it directly. I just happened to need it in a CTF. |
I will like to fix this for ODHack @ivpavici |
In fact, this one should probably not be tagged as ODHack, and should have been closed. |
Describe the bug
I know this function is deprecated but i needed to use it for a CTF.
description of
Invocation
type says that the default value forsignature
is[]
.but when its not specificed an error is thrown
To Reproduce
call
invokeFunction
without specifyingsignature
fieldExpected behavior
signature
should use empty array as default valueAdditional context
I am willing to open a PR for this if needed.
The text was updated successfully, but these errors were encountered: