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

Add Sphinx build config and more user docs, docstrings, type annotations, etc. #70

Merged
merged 14 commits into from
Apr 12, 2022

Conversation

JWCook
Copy link
Contributor

@JWCook JWCook commented Apr 7, 2022

Closes #69, updates #49

Let me know if you have any questions about how Sphinx works or about the extensions used. These tools have a bit of a learning curve, but once everything is set up you can mostly forget about it.

Besides the changes to build and publish docs, I've added and edited quite a bit of documentation, mainly in the Readme. A diff is not very useful here, so see the rendered doc instead: https://github.com/JWCook/PyrateLimiter/blob/docs/README.md

I've tried to organize it roughly in order of what I think a new user will want to know first:

  • Basic info
    • Feature summary
    • Install instructions
    • A couple basic examples that can be easily copy-pasted
  • More detailed/advanced info
    • Details on handling rate limit exceptions or delays
    • Details on other usage options (decorator, contextmanager, async, etc.)
    • Bucket backends
  • Contributing guide (now on a separate page)

Please look that over and let me know what you think.

@JWCook JWCook force-pushed the docs branch 2 times, most recently from ddafc82 to 1be7b96 Compare April 7, 2022 20:18
@codecov
Copy link

codecov bot commented Apr 7, 2022

Codecov Report

Merging #70 (7d19a10) into master (0632081) will increase coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master      #70      +/-   ##
==========================================
+ Coverage   98.15%   98.18%   +0.02%     
==========================================
  Files           8        8              
  Lines         380      386       +6     
  Branches       34       33       -1     
==========================================
+ Hits          373      379       +6     
  Misses          4        4              
  Partials        3        3              
Impacted Files Coverage Δ
pyrate_limiter/bucket.py 94.16% <100.00%> (ø)
pyrate_limiter/exceptions.py 100.00% <100.00%> (ø)
pyrate_limiter/limit_context_decorator.py 100.00% <100.00%> (ø)
pyrate_limiter/limiter.py 100.00% <100.00%> (ø)
pyrate_limiter/request_rate.py 100.00% <100.00%> (ø)
pyrate_limiter/sqlite_bucket.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0632081...7d19a10. Read the comment docs.

@JWCook JWCook force-pushed the docs branch 4 times, most recently from 4b83c97 to 8ed0a97 Compare April 7, 2022 23:00
@vutran1710
Copy link
Owner

@JWCook Looks great to me

@JWCook JWCook force-pushed the docs branch 3 times, most recently from 6b7cd3a to 3fc7221 Compare April 10, 2022 16:24
@JWCook JWCook marked this pull request as ready for review April 10, 2022 16:25
@JWCook
Copy link
Contributor Author

JWCook commented Apr 10, 2022

@vutran1710 Okay, I think this is ready to go. I did a manual build from my branch so you can see a preview here: https://pyrate-limiter.readthedocs.io

Were you able to add that webhook to trigger doc builds? Details here. Once that's done, it will rebuild the docs every time you push to the master branch. Or it can be built only for git tags or other conditions, if you prefer.

@JWCook JWCook changed the title Set up Sphinx documentation build Add Sphinx build config and more user docs, docstrings, type annotations, etc. Apr 10, 2022
@vutran1710 vutran1710 merged commit a10e3a8 into vutran1710:master Apr 12, 2022
@JWCook JWCook deleted the docs branch September 28, 2022 18:12
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.

Set up Sphinx documentation builds and publish to readthedocs.io
2 participants