zkapp-cli
zkapp-cli copied to clipboard
Properly handle error responses from the Node
trafficstars
CLI throws an error:
zk deploy -y local
✔ Build project
✔ Generate build.json
✔ Choose smart contract
The 'Add' smart contract will be used
for this network as specified in config.json.
✔ Generate verification key (takes 10-30 sec)
✔ Build transaction
✔ Send to network
zk deploy [alias]
Deploy or redeploy a zkApp
Options:
-y, --yes Respond `yes` to all confirmation prompts.
Allows running non-interactively within a script. [boolean]
-h, --help Show help [boolean]
-v, --version Show version number [boolean]
TypeError: errors.map is not a function
at getErrorMessage (/Users/shymkiv/.nvm/versions/node/v16.15.1/lib/node_modules/zkapp-cli/src/lib/deploy.js:509:12)
at deploy (/Users/shymkiv/.nvm/versions/node/v16.15.1/lib/node_modules/zkapp-cli/src/lib/deploy.js:368:13)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Object.handler (/Users/shymkiv/.nvm/versions/node/v16.15.1/lib/node_modules/zkapp-cli/src/bin/index.js:65:21)
In case if Node fails to complete the requested operation with empty or no response.
[2022-7-10 10:48:01.833664]Init__Coda_run: Exception while handling REST server request: $error
$error = "(monitor.ml.Error(Failure\"Invalid rich scalar: Signature 7mX7719b3yX6A4oQhcYTDVsWT3BybULL3aAFKQVmUq3ARkTD7bZgfBdyCSVzstgXSJDrgBZGLk1DvisoRKZUckJHNx7NuSRA\")(\"Raised at Stdlib.failwith in file \\\"stdlib.ml\\\", line 29, characters 17-33\"\"Called from Base__Option.map in file \\\"src/option.ml\\\", line 265, characters 23-28\"\"
@shimkiv Can you post the contents of your config.json and output from zk system please?
- https://o1-labs.slack.com/archives/C028Q27R8UC/p1664352732497679
-
System: OS: macOS 12.6 CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz Binaries: Node: 16.15.1 - ~/.nvm/versions/node/v16.15.1/bin/node Yarn: 1.22.19 - /usr/local/bin/yarn npm: 8.11.0 - ~/.nvm/versions/node/v16.15.1/bin/npm npmPackages: snarkyjs: Not Found (not in a project) npmGlobalPackages: zkapp-cli: 0.4.17
Stale issue. Already fixed. Errors of unexpected types are handled better via an update Martin made to error handling