-
Notifications
You must be signed in to change notification settings - Fork 29
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
RTD results can cause exception #394
Conversation
The Read the docs get builds API can return an empty results set. { "count": 0, "next": null, "previous": null, "results": [] } This causes an exception in the validator due to no check for empty set. This simple change checks and handles that empty set
I think this is probably good, but I I'd like to understand why the ones on the list currently are returning empty lists before merging it, so that they are less likely to fall through the cracks. Maybe we should have a seperate section on the report for "empty list of results from RTD" or something similar. In general I don't think we'd expect an empty list, so it's something we'd want to look into if it does happen. For instance https://github.com/adafruit/Adafruit_CircuitPython_NeoPxl8 is on the list and indeed looking at the readme badge looks like there is indeed some issue with RTD. But if you click through the badge it does take you to a seemingly fine looking docs page: https://docs.circuitpython.org/projects/neopxl8/en/latest/ I haven't looked as close into any of the rest but I'd like to figure out what is up with them before we merge this and they get removed from the report. |
@slaftos with this change do the ones that have empty results lists still end up being flagged in the infrastructure issues report under one of the sections? If not I think we want to go ahead and make a new section in the report and list them there. Most or all of these did indeed have issues that were worth looking in to so I don't think we want to simply omit any that have similar problems in the future from the report. 5 of them simply had the wrong readthedocs slug in the badge URL of their readme.rst file. Adabot parses the slug from that line so that caused this to ask the API for data about the wrong slug which ended up as the empty list of results. The last remaining one is https://github.com/adafruit/Adafruit_CircuitPython_BusDevice which is an odd one out. I'm not really sure what the issue is with that one. Its slug seems fine so it's not the same issue as the others. My best guesses are 1) something related to busdevice having a core implementation and thus likely a core module existing inside of RTD somewhere in addition to the library implementation. or 2) the busdevice RTD seems to be configured differently such that it is creating a version inside of RTD for every tagged release of the library with the name of the tag. Most circuitpython libraries do not do this as far as I am aware. The ones I'm familiar with just have |
They actually move to an error of Failed to load RTD build status (Unknown error). instead of just A programmatic error occurred. So visibility remains it is just a bit clearer where the actual fault is. I did not see the programmatic error on Bus_Device |
Note that the 16th infrastructure report Bus_device has dropped off the A programmatic error occurred list. So the last update to Bus_device must have resolved the issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you! looks good to me.
The Read the docs get builds API can return an empty results set.
{ "count": 0, "next": null, "previous": null, "results": [] }
This causes an exception in the validator due to no check for empty set.
This simple change checks and handles that empty set
This was the cause of the bulk of the A programmatic error occurred in the Library Infrastructure report