From 4e8a4d74bb2ea5fd0d20003dd78f1c7c3995675d Mon Sep 17 00:00:00 2001 From: Jonathan Huot Date: Thu, 19 Jun 2025 17:29:13 +0200 Subject: [PATCH 1/2] Added graphviz/dot dependency --- .readthedocs.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index d76e42c7..6bdea12d 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -4,6 +4,8 @@ build: os: ubuntu-22.04 tools: python: "3.12" + apt_packages: + - graphviz # used for "dot" graphs sphinx: builder: html configuration: docs/conf.py From a015b446622f2b925517501fe484c10eff7a83c0 Mon Sep 17 00:00:00 2001 From: Jonathan Huot Date: Sat, 21 Jun 2025 09:48:27 +0200 Subject: [PATCH 2/2] Replace pyenv with uv in documentation and tooling (#910) * Removed black & lint since we use ruff * Add uv to use multiple python versions * Excluded folders when using make --- Makefile | 19 ++++++------------- docs/contributing.rst | 28 +++++++++++++++++----------- ruff.toml | 1 + 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a/Makefile b/Makefile index 9622f70d..5313c80a 100644 --- a/Makefile +++ b/Makefile @@ -34,44 +34,37 @@ clean-build: @rm -fr dist/ @rm -fr *.egg-info -format fmt black: - black . - -lint ruff: - ruff check . - test: - tox + uvx --with tox-uv tox bottle: #--------------------------- # Library refinitiv/bottle-oauthlib # Contacts: Jonathan.Huot cd bottle-oauthlib 2>/dev/null || git clone https://github.com/refinitiv/bottle-oauthlib.git - cd bottle-oauthlib && sed -i.old 's,deps =,deps= --editable=file://{toxinidir}/../,' tox.ini && sed -i.old '/oauthlib/d' requirements.txt && tox + cd bottle-oauthlib && sed -i.old 's,deps =,deps= --editable=file://{toxinidir}/../,' tox.ini && sed -i.old '/oauthlib/d' requirements.txt && uvx --with tox-uv tox django: #--------------------------- # Library: evonove/django-oauth-toolkit # Contacts: evonove,masci - # (note: has tox.ini already) cd django-oauth-toolkit 2>/dev/null || git clone https://github.com/evonove/django-oauth-toolkit.git - cd django-oauth-toolkit && sed -i.old 's,deps =,deps= --editable=file://{toxinidir}/../,' tox.ini && tox + cd django-oauth-toolkit && sed -i.old 's,deps =,deps= --editable=file://{toxinidir}/../,' tox.ini && uvx --with tox-uv tox requests: #--------------------------- # Library requests/requests-oauthlib # Contacts: ib-lundgren,lukasa cd requests-oauthlib 2>/dev/null || git clone https://github.com/requests/requests-oauthlib.git - cd requests-oauthlib && sed -i.old 's,deps=,deps = --editable=file://{toxinidir}/../[signedtoken],' tox.ini && sed -i.old '/oauthlib/d' requirements.txt && tox + cd requests-oauthlib && sed -i.old 's,oauthlib.*,--editable=file://{toxinidir}/../../[signedtoken],' requirements.txt && uvx --with tox-uv tox dance: #--------------------------- # Library singingwolfboy/flask-dance # Contacts: singingwolfboy cd flask-dance 2>/dev/null || git clone https://github.com/singingwolfboy/flask-dance.git - cd flask-dance && sed -i.old 's,deps=,deps = --editable=file://{toxinidir}/../,' tox.ini && sed -i.old '/oauthlib/d' requirements.txt && tox + cd flask-dance && sed -i.old 's;"oauthlib.*";"oauthlib @ file://'`pwd`'/../";' pyproject.toml && uv venv && uv pip install -e '.[test]' && ./.venv/bin/coverage run -m pytest .DEFAULT_GOAL := all .PHONY: clean test bottle dance django flask requests -all: lint test bottle dance django flask requests +all: test bottle dance django flask requests diff --git a/docs/contributing.rst b/docs/contributing.rst index 9da1370c..19c08190 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -159,24 +159,22 @@ all versions conveniently at once can be done using `Tox`_. $ tox -Tox requires you to have `virtualenv`_ installed as well as respective python -version. We recommend using `pyenv`_ to install those Python versions. +Tox requires you to have respective python versions. We recommend using `uv`_ to install those Python versions. -We recommend using the latest patch version for each Python version we support and the latest PyPy versions. -The versions beloew may not be up to date. .. sourcecode:: bash - $ pyenv install -l # check which versions you want to use - $ pyenv install 3.8.18 - $ pyenv install 3.11.7 - $ pyenv install pypy3.10-7.3.13 + $ uv tool install tox --with tox-uv + $ uv python list # check which versions you want to use + $ uv python install 3.8 3.9 3.10 3.11 3.12 3.13 + $ uv python install pypy3 + $ uvx --with tox-uv tox # that run all tests with all python versions + .. _`Tox`: https://tox.readthedocs.io/en/latest/install.html -.. _`virtualenv`: https://virtualenv.pypa.io/en/latest/installation/ -.. _`pyenv`: https://github.com/pyenv/pyenv +.. _`uv`: https://docs.astral.sh/uv/#python-versions -Test upstream applications +Test downstream applications ----------------------------------- Remember, OAuthLib is used by several 3rd party projects. If you think you @@ -186,6 +184,14 @@ submit a breaking change, confirm that other projects builds are not affected. $ make +Note be sure you are using ``uv`` as explained before with all python versions, including those from downstream libraries, to have all test cases running. + +As of 2025, additional downstreams python versions are as below: + +.. sourcecode:: bash + + $ uv python install pypy3.10 + If you add code, add tests! -------------------------------------- diff --git a/ruff.toml b/ruff.toml index ec45dd4b..9dffa813 100644 --- a/ruff.toml +++ b/ruff.toml @@ -5,6 +5,7 @@ # When switching from ruff.toml to pyproject.toml, use the section names that # start with [tool.ruff +exclude = ["flask-dance", "requests-oauthlib", "bottle-oauthlib", "django-oauth-toolkit"] # [tool.ruff] lint.select = [ pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy