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

Make upload.py compatible with existing FS upload #6788

Merged
merged 3 commits into from Nov 17, 2019

Conversation

earlephilhower
Copy link
Collaborator

PR #6765 introduced an incompatibility with the existing Java uploaders
for SPIFFS and LittleFS, breaking them because of the upload.py
parameter format change to support single stage erase/upload.

Add in patch to silently eat the single --end and to parse the write
address and filename properly as generated by calls from the plugins,
while retaining compatibility with the current IDE changes.

PR esp8266#6765 introduced an incompatibility with the existing Java uploaders
for SPIFFS and LittleFS,  breaking them because of the upload.py
parameter format change to support single stage erase/upload.

Add in patch to silently eat the single --end and to parse the write
address and filename properly as generated by calls from the plugins,
while retaining compatibility with the current IDE changes.
@earlephilhower
Copy link
Collaborator Author

Fixes #6777

Either this or #6781 should be merged ASAP. #6781 reinstates the old path of pass-thru when --end is detected at the EOL, while this one tries to fit the old way into the new format and avoid separate parsing paths. Either should solve it, but it's a style choice that I'm relatively indifferent about...

Make upload.py more concise and pythonic.

Use the "write_flash" argument in platform.txt for uploads instead of
assuming anything that is a file is the bin to upload.
@earlephilhower
Copy link
Collaborator Author

@d-a-v I'm sitting on the SC19 expo floor waiting for some networking to be done, so I can't actually test this. It's what was discussed on the channel. If you could give it a try before approving/requesting changed it'd be much appreciated.

@esp8266 esp8266 deleted a comment from earlephilhower Nov 17, 2019
@gnu-emu
Copy link

gnu-emu commented Nov 17, 2019

I cloned https://github.com/earlephilhower/Arduino.git -b fixfsupload , installed it using-git-version doc on Arduino 1.8.10 (with portable directory on Ubuntu Bionic) and for me https://github.com/esp8266/arduino-esp8266fs-plugin/releases/download/0.4.0/ESP8266FS-0.4.0.zip is working. Sketch upload successful and working on the esp.

@earlephilhower
Copy link
Collaborator Author

@gnu-emu thanks very much for the report and your other PRs on this! It's one thing to report a bug, but a much harder thing to try and fix it...

Anyway, I think at some point we'll drop upload.py and call the esptool.py directly from the plugins and from the IDE (3.0 probably). The suggestions you've got on the other repos will probably make sense then.

Copy link
Collaborator

@d-a-v d-a-v left a comment

Choose a reason for hiding this comment

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

WorksForMe

@devyte devyte merged commit dabf4c5 into esp8266:master Nov 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants