1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-19 23:22:16 +03:00

Log all exceptions in upload.py (#8813)

Currently some exceptions cause a exit code 2, but without any relevant error message.

As an example, I had an issue with my USB drivers. But the only message I saw using the Arduino IDE was: uploading error: exit status 2. With this code change I could see a more specific Resource busy error message, which helped me identify the actual problem.
This commit is contained in:
Edan Schwartz 2023-01-17 20:16:48 -06:00 committed by GitHub
parent 6af463baaf
commit 39b41379ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -65,7 +65,7 @@ if erase_addr:
try:
esptool.main(cmdline)
except esptool.FatalError as e:
except Exception as e:
sys.stderr.write('\nA fatal esptool.py error occurred: %s' % e)
finally:
if erase_file: