I started a new project, and when I hit verify/compile I got an immediate error "Marshal called with Nil".
That, as it turns out, is what is provided if you forget to select a board. IMO, this should be replaced (or added to ) to more accurately suggest the root cause. My search results indicate this has confused others for a long time.
Perhaps a check with a friendlier reminder before the compilers is called will help the less bright (or forgetful) bulbs out there,
Hi @weshowe . Thanks for your report.
This bug was fixed last week:
arduino:master
← cmaglie:fix_compile_err_marshaling
opened 10:38AM - 24 Aug 22 UTC
**Please check if the PR fulfills these requirements**
- [X] The PR has no du… plicates (please search among the [Pull Requests](https://github.com/arduino/arduino-cli/pulls)
before creating one)
- [X] The PR follows
[our contributing guidelines](https://arduino.github.io/arduino-cli/latest/CONTRIBUTING/#pull-requests)
- [X] Tests for the changes have been added (for bug fixes / features)
- [ ] Docs have been added / updated (for bug fixes / features)
- [ ] `UPGRADING.md` has been updated with a migration guide (for breaking changes)
* **What kind of change does this PR introduce?**
Fix the error messages from `compile`, they were not correctly encoded in the response.
- **What is the current behavior?**
The message `grpc: error while marshaling: proto: Marshal called with nil` appeared instead of the real error message. See #1812 for details.
* **What is the new behavior?**
The correct error message is outputted.
- **Does this PR introduce a breaking change, and is [titled accordingly](https://arduino.github.io/arduino-cli/latest/CONTRIBUTING/#breaking)?**
No
* **Other information**:
Fix #1812
Please try the latest nightly build. The download links are listed here:
https://www.arduino.cc/en/software#nightly-builds
Even though the "grpc: error while marshaling: proto: Marshal called with nil
" error message was a bug, even the intended error message was not so clear, since it uses terminology more applicable to Arduino CLI users than Arduino IDE. This was also improved last week:
arduino:main
← arduino:msg-upload-not-possible
opened 11:32AM - 25 Aug 22 UTC
### Motivation
If the user presses the upload button and no board is selected, … a message should appear warning what went wrong while uploading. Since verify takes place before upload, the same message that is given when the user tries to compile a sketch without selecting a board should be shown. On the other hand, this message is not very clear, so it should be updated.
### Change description
Communicate to user when upload is impossible due to no board selection.
Make error message from compiling without board selected more user friendly.
### Other information
Closes #845.
Closes #62.
This fix depends on the changes made here: https://github.com/arduino/arduino-cli/pull/1848. Without it it is not possible to verify that #62 is resolved.
### Reviewer checklist
* [ ] PR addresses a single concern.
* [ ] The PR has no duplicates (please search among the [Pull Requests](https://github.com/arduino/arduino-ide/pulls) before creating one)
* [ ] PR title and description are properly filled.
* [ ] Docs have been added / updated (for bug fixes / features)
system
Closed
February 26, 2023, 6:23pm
3
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.