-
Notifications
You must be signed in to change notification settings - Fork 115
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
platformio_upload.py with authentication not working #176
Comments
I had the same symptoms. To work around the script's bug, make sure to specify When I was left with a 401 error, it was because I was providing my username/password values wrapped in single quotes. i.e. wrong:
good:
|
@mleroy removing the @ayushsharma82 is this something that can be updated/added in the documentation? |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue was closed because it has been stalled for 5 days with no activity. |
When I configure authentication the upload with platformio_upload.py script is not working. When using the script without authentication everything works fine.
The first thing I noticed in the script is that
checkAuthResponse = requests.get(f"{upload_url_compatibility}/update")
should be (I think)checkAuthResponse = requests.get(f"{upload_url_compatibility}")
otherwise you end up with a URL ending with/upload/upload
sinceupload_url_compatibility
already contains/upload
.When using the original script I get the following lines in the log:
When I remove
/upload
the script tries to authenticate withdoUpdateAuth = requests.get(start_url, headers=start_headers, auth=auth)
but it fails with status code401
again.I did configure the correct username and password in the platformio.ini file with
custom_username
andcustom_password
.platformio.ini file:
ElegantOTA setup:
I suppose it has something to do with one of the following lines
but I'm not sure.
Anyone else that has this issue? Or is this issue known?
The text was updated successfully, but these errors were encountered: