Closed brunopgalvao closed 1 week ago
So yes, the user should just pass in arguments without Rust syntax, so if the argument is None
then have it be empty e.g.
This:
pop up contract --constructor new --args 10000000, 'None', 'Some("AWE")', 10
Would be:
pop up contract --constructor new --args 10000000, , "AWE", 10
All the following variations should be okay:
pop up contract --constructor new --args 10000000, "", "AWE", 10
OR
pop up contract --constructor new --args supply=10000000, name=, symbol="AWE", decimals=10
OR
pop up contract --constructor new --args supply=10000000, name="", symbol=AWE, decimals="10"
Pop CLI should (attempt) to parse into the appropriate type.
https://github.com/r0gue-io/pop-cli/pull/330 solves this issue
When instantiating a contract that expects
String
's as arguments, Pop CLI fails:For example, instantiating the PSP22 contract:
The following error is emitted:
For it to work, I need to wrap the strings in
Some()
with''
around so thatzsh
does not complain: