gabrieldemarmiesse / python-on-whales

An awesome Python wrapper for an awesome Docker CLI!
MIT License
561 stars 102 forks source link

Documentation deployment doesn't work anymore #489

Closed kashyab12 closed 1 year ago

kashyab12 commented 1 year ago

485

Note: I have included fixes for each of the warnings logged during the docs' build process. According to the warning messages, type annotations wouldn't show up for the specified vars unless the warnings were fixed.

This being my first PR I worked primarily via the advice given in the description of the original bug i.e. narrow down which commit broke the docs. I tried reverting each commit one at a time (after checking out v0.64.2) however the RecursionError would still occur. After taking a closer look at the stack trace, and also messing with the markdown file and noticing that the presence of the identifier (ex: python_on_whales.docker_client.DockerClient) would cause the issue, I focused my efforts towards looking at issues with the mkdocstrings-python package. I couldn't find much about jinja2 breaking mkdocs (except for https://github.com/mkdocs/mkdocs/issues/2799), however I did find good amounts of discussion regarding Griffe causing issues (https://github.com/mkdocstrings/mkdocstrings/issues/382, and https://github.com/mkdocstrings/griffe/issues/79). According to the changelog, mkdocstrings-python enforced a version upper bound on griffe in version 1.3, hence why I chose to bump to this particular version. I tried out 1.2 as well however still ran into the same issue.

gabrieldemarmiesse commented 1 year ago

Thank you for this thorough investigation. I'll take a look at this PR this week

gabrieldemarmiesse commented 1 year ago

I just made a copy of your branch and ran the deployment job for the docs from this, and it worked like a charm. Thank you for the version fix and all the other small changes to the docstrings. This is really the kind of pull requests that I love, they just work :) This PR makes me glad I'm doing open source. Many thanks :)