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

Return a different exit code if the upload to qgis.org has failed #221

Merged
merged 1 commit into from
Jun 12, 2023

Conversation

Gustry
Copy link
Collaborator

@Gustry Gustry commented Apr 11, 2023

While writing this quick PR, I was pretty sure I have a opened ticket either in this repository or in the QGIS django repository, but I couldn't find any :(

Only this commit as reference : 64216b5 with some discussions.

Everytime I release a new version of QuickOSM, it failed on the upload to the OSGEO server.
The logs from qgis-plugin-ci are not enough (my commit above trying to increase some debug).

We do not need to send the message twice, with the logger and with the sys.exist. I think the logger is enough, no ?
We can read twice === A protocol error occurred ===

Exemple :


Run qgis-plugin-ci release 2.2.2 --github-token *** --transifex-token *** --osgeo-username *** --osgeo*** --create-plugin-repo
  qgis-plugin-ci release 2.2.2 --github-token *** --transifex-token *** --osgeo-username *** --osgeo*** --create-plugin-repo
  shell: /usr/bin/bash -e {0}
  env:
    RELEASE_VERSION: 2.2.2
    pythonLocation: /opt/hostedtoolcache/Python/3.10.10/x64
    PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.10.10/x64/lib/pkgconfig
    Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.10.10/x64
    Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.10.10/x64
    Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.10.10/x64
    LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.10.10/x64/lib
Plugin archive created: QuickOSM.2.2.2.zip (6.54 Mo)
2023-04-11 14:00:56||ERROR||release||=== A protocol error occurred ===
URL: ***:******@plugins.qgis.org:443/plugins/RPC2/
HTTP/HTTPS headers: {'Date': 'Tue, 11 Apr 2023 14:00:56 GMT', 'Content-Type': 'text/html; charset=utf-8', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Vary': 'Cookie', 'Set-Cookie': 'sessionid=8pn06204q3417g96g1o3odivmrj9094j; expires=Tue, 25 Apr 2023 14:00:56 GMT; HttpOnly; Max-Age=1209600; Path=/; SameSite=Lax', 'CF-Cache-Status': 'DYNAMIC', 'Report-To': '{"endpoints":[{"url":"https:\\/\\/a.nel.cloudflare.com\\/report\\/v3?s=sW8X9n%2FSbaxNLLe7E5edIubdCiTyUWeyQkbHwu%2FuY1Kul1YXFKcPVcKFwnydtiAKwwnYzwqDN9Xmv0Zv77pXeHikPNDAk8L9wJ781odRhpVYrk%2BVEMU87UMZJNJ9yE6nR5yS"}],"group":"cf-nel","max_age":604800}', 'NEL': '{"success_fraction":0,"report_to":"cf-nel","max_age":604800}', 'Server': 'cloudflare', 'CF-RAY': '7b63c219dcf84864-DFW', 'alt-svc': 'h3=":443"; ma=86400, h3-29=":443"; ma=86400'}
Error code: 400
Error message: Bad Request
Plugin path: QuickOSM.2.2.2.zip
=== A protocol error occurred ===
URL: ***:******@plugins.qgis.org:443/plugins/RPC2/
HTTP/HTTPS headers: {'Date': 'Tue, 11 Apr 2023 14:00:56 GMT', 'Content-Type': 'text/html; charset=utf-8', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Vary': 'Cookie', 'Set-Cookie': 'sessionid=8pn06204q3417g96g1o3odivmrj9094j; expires=Tue, 25 Apr 2023 14:00:56 GMT; HttpOnly; Max-Age=1209600; Path=/; SameSite=Lax', 'CF-Cache-Status': 'DYNAMIC', 'Report-To': '{"endpoints":[{"url":"https:\\/\\/a.nel.cloudflare.com\\/report\\/v3?s=sW8X9n%2FSbaxNLLe7E5edIubdCiTyUWeyQkbHwu%2FuY1Kul1YXFKcPVcKFwnydtiAKwwnYzwqDN9Xmv0Zv77pXeHikPNDAk8L9wJ781odRhpVYrk%2BVEMU87UMZJNJ9yE6nR5yS"}],"group":"cf-nel","max_age":604800}', 'NEL': '{"success_fraction":0,"report_to":"cf-nel","max_age":604800}', 'Server': 'cloudflare', 'CF-RAY': '7b63c219dcf84864-DFW', 'alt-svc': 'h3=":443"; ma=86400, h3-29=":443"; ma=86400'}
Error code: 400
Error message: Bad Request
Plugin path: QuickOSM.2.2.2.zip
Error: Process completed with exit code 1.

From a CI point of view, I would like know if it was only the upload to qgis.org which failed with a specific exit code.

I can still create a issue on QGIS-Django repository.

@Gustry Gustry requested review from 3nids and Guts April 11, 2023 15:31
@Guts
Copy link
Collaborator

Guts commented Apr 12, 2023

Even with the --verbose option the log is not enough? I did not see it enabled in your commands

@Gustry Gustry force-pushed the exit-code-qgis-org branch from a17cab7 to a67852e Compare June 1, 2023 14:25
@Gustry Gustry force-pushed the exit-code-qgis-org branch from a67852e to e590e18 Compare June 12, 2023 11:56
@Gustry Gustry merged commit 7244820 into opengisch:master Jun 12, 2023
@Gustry Gustry deleted the exit-code-qgis-org branch June 12, 2023 11:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants