-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Build marked as "Failed" when "exit 183" ("skip the build") is used #10567
Comments
This URL seems to say that the build is still running, wheareas it was already reported as a failure to GitHub.
|
I triggered a new doc build job: https://readthedocs.org/projects/cpython-previews/builds/21404472/ It completed as expected as "Build cancelled", and was reported as expected as a success to GitHub PR: good! The strange thing is that the first job https://readthedocs.org/projects/cpython-previews/builds/21404205/ executed |
Looking at timestamps in the logs: https://beta.readthedocs.org/api/v2/build/21404205.txt Seems it logged each command three times, rather than running three times. The timestamps for each repeated command is identical. |
Hi, we were doing a deploy during that time, so that's probably the cause of the duplicate commands (to save the commands we hit an API, if this is retried, it will duplicate the commands). |
Since the following job was fine, feel free to close the issue if you consider it to be fixed. |
Sometimes it happens the web servers are congested and the builder retries the API call to save the command in the database. However, one of the first attempts finally ended up working resulting in the command being saved twice. This small chunk of code checks for the existence of the command before saving it into the database and logs a warning and return 204 if it already exists, instead of re-saving it again. It's not a perfect solution, but it could help under similar circumstances. Related #10567
* Build: skip duplicated commands Sometimes it happens the web servers are congested and the builder retries the API call to save the command in the database. However, one of the first attempts finally ended up working resulting in the command being saved twice. This small chunk of code checks for the existence of the command before saving it into the database and logs a warning and return 204 if it already exists, instead of re-saving it again. It's not a perfect solution, but it could help under similar circumstances. Related #10567 * Test case for duplicated BuildCommandResult * Add `start_date` to the filter * Typo * Update readthedocs/api/v2/views/model_views.py Co-authored-by: Santos Gallegos <stsewd@proton.me> --------- Co-authored-by: Santos Gallegos <stsewd@proton.me>
Details
Expected Result
ReadTheDocs documentation says that exit 183 can be used to skip a build: I expect the build to be reported to GitHub as a "success".
Actual Result
The build was reported to GitHub as a failure:
My related PR which triggered the doc build: python/cpython#107235
The text was updated successfully, but these errors were encountered: