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

allow arrays to be passed via --app-init-params #623

Merged
merged 1 commit into from
Jul 31, 2019

Conversation

mikec
Copy link
Contributor

@mikec mikec commented Jul 12, 2019

web3.eth.abi.encodeFunctionCall expects a javascript array, which needs to be parse from the CLI input

🦅 Pull Request

Closes #320

run command doesn't support arrays as --app-init-params

🚨 Test instructions

create a contract that takes an address[] type as a param for the initialize() function. Try executing run command with --app-init-params ["<address>"]

web3.eth.abi.encodeFunctionCall expects a javascript array, which needs to be parse from the CLI input
@kernelwhisperer
Copy link
Contributor

Solves #320
Related to #369

mikec added a commit to levelkdev/oracle-manager-app that referenced this pull request Jul 15, 2019
Copy link
Contributor

@0xGabi 0xGabi left a comment

Choose a reason for hiding this comment

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

Thanks @mikec works great. We should explain as clear as possible on documentation how to use it. It took me a while to figure out 😅

For reference now arrays able to be passed like:

--app-init-args ["'0xB24b...73a7', '0xB24b...73a7'"]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve argument type coercing by inspecting the ABI
3 participants