Open ymekuria opened 2 years ago
Related: To make it more DRY, we could store the indent string as a var and prepend it to messages.
Related: To make it more DRY, we could store the indent string as a var and prepend it to messages.
I like that idea!
The output in the original post looks ok in my terminal:
✔ Build project
✔ Generate build.json
✔ Choose smart contract
Only one smart contract exists in the project: Add
Your config.json was updated to always use this
smart contract when deploying to this network.
I think the affected error messages indentation on 2nd lines are fixed here: https://github.com/o1-labs/zkapp-cli/pull/191 Updated the title to focus on making indentation DRY, to prevent such errors. (Another solution would be a method that accepts an error string, makes it red, and adds a line break and two spaces automatically while keeping the error string within a certain max char length and breaking intelligently to not split words.)
The error message formatting appears inconsistent after the first line. The first line is indented but every following line appears to be aligned to the left of the screen.
✔ Build project ✔ Generate build.json ✔ Choose smart contract The 'Add' smart contract will be used for this network as specified in config.json. Failed to find the "Add" smart contract in your build directory. Check that you have exported your smart contract class using a named export and try again.