Skip to content

Commit

Permalink
Merge branch '3.1.x'
Browse files Browse the repository at this point in the history
  • Loading branch information
davidism committed May 13, 2024
2 parents a516a99 + e82013c commit b002d9c
Show file tree
Hide file tree
Showing 19 changed files with 394 additions and 199 deletions.
1 change: 1 addition & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ jobs:
fail-fast: false
matrix:
include:
- {python: '3.13'}
- {python: '3.12'}
- {name: Windows, python: '3.12', os: windows-latest}
- {name: Mac, python: '3.12', os: macos-latest}
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ ci:
autoupdate_schedule: monthly
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.4.3
rev: v0.4.4
hooks:
- id: ruff
- id: ruff-format
Expand Down
21 changes: 18 additions & 3 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,22 @@ Unreleased
- Use ``flit_core`` instead of ``setuptools`` as build backend.


Version 3.1.5
-------------

Unreleased

- Calling sync ``render`` for an async template uses ``asyncio.run``.
:pr:`1952`
- Avoid unclosed ``auto_aiter`` warnings. :pr:`1960`
- Return an ``aclose``-able ``AsyncGenerator`` from
``Template.generate_async``. :pr:`1960`
- Avoid leaving ``root_render_func()`` unclosed in
``Template.generate_async``. :pr:`1960`
- Avoid leaving async generators unclosed in blocks, includes and extends.
:pr:`1960`


Version 3.1.4
-------------

Expand Down Expand Up @@ -143,9 +159,8 @@ Released 2021-05-18
extensions shows more relevant context. :issue:`1429`
- Fixed calling deprecated ``jinja2.Markup`` without an argument.
Use ``markupsafe.Markup`` instead. :issue:`1438`
- Calling sync ``render`` for an async template uses ``asyncio.run``
on Python >= 3.7. This fixes a deprecation that Python 3.10
introduces. :issue:`1443`
- Calling sync ``render`` for an async template uses ``asyncio.new_event_loop``
This fixes a deprecation that Python 3.10 introduces. :issue:`1443`


Version 3.0.0
Expand Down
3 changes: 0 additions & 3 deletions docs/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -515,9 +515,6 @@ environment to compile different code behind the scenes in order to
handle async and sync code in an asyncio event loop. This has the
following implications:

- Template rendering requires an event loop to be available to the
current thread. :func:`asyncio.get_running_loop` must return an
event loop.
- The compiled code uses ``await`` for functions and attributes, and
uses ``async for`` loops. In order to support using both async and
sync functions in this context, a small wrapper is placed around
Expand Down
2 changes: 1 addition & 1 deletion requirements/build.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ build==1.2.1
# via -r build.in
packaging==24.0
# via build
pyproject-hooks==1.0.0
pyproject-hooks==1.1.0
# via build
156 changes: 68 additions & 88 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,164 +5,144 @@
# pip-compile dev.in
#
alabaster==0.7.16
# via
# -r docs.txt
# sphinx
babel==2.14.0
# via
# -r docs.txt
# sphinx
# via sphinx
attrs==23.2.0
# via
# outcome
# trio
babel==2.15.0
# via sphinx
build==1.2.1
# via pip-tools
cachetools==5.3.3
# via tox
certifi==2024.2.2
# via
# -r docs.txt
# requests
# via requests
cfgv==3.4.0
# via pre-commit
chardet==5.2.0
# via tox
charset-normalizer==3.3.2
# via requests
click==8.1.7
# via
# -r docs.txt
# requests
# pip-compile-multi
# pip-tools
colorama==0.4.6
# via tox
distlib==0.3.8
# via virtualenv
docutils==0.21.2
# via
# -r docs.txt
# sphinx
filelock==3.13.4
# via sphinx
filelock==3.14.0
# via
# tox
# virtualenv
identify==2.5.36
# via pre-commit
idna==3.7
# via
# -r docs.txt
# requests
# trio
imagesize==1.4.1
# via
# -r docs.txt
# sphinx
# via sphinx
iniconfig==2.0.0
# via
# -r tests.txt
# -r typing.txt
# pytest
jinja2==3.1.3
# via
# -r docs.txt
# sphinx
# via pytest
jinja2==3.1.4
# via sphinx
markupsafe==2.1.5
# via
# -r docs.txt
# jinja2
# via jinja2
mypy==1.10.0
# via -r typing.txt
# via -r typing.in
mypy-extensions==1.0.0
# via
# -r typing.txt
# mypy
# via mypy
nodeenv==1.8.0
# via
# -r typing.txt
# pre-commit
# pyright
# via pre-commit
outcome==1.3.0.post0
# via trio
packaging==24.0
# via
# -r docs.txt
# -r tests.txt
# -r typing.txt
# build
# pallets-sphinx-themes
# pyproject-api
# pytest
# sphinx
# tox
pallets-sphinx-themes==2.1.3
# via -r docs.txt
# via -r docs.in
pip-compile-multi==2.6.3
# via -r dev.in
pip-tools==7.4.1
# via pip-compile-multi
platformdirs==4.2.1
# via
# tox
# virtualenv
pluggy==1.5.0
# via
# -r tests.txt
# -r typing.txt
# pytest
# tox
pre-commit==3.7.0
pre-commit==3.7.1
# via -r dev.in
pygments==2.17.2
# via
# -r docs.txt
# sphinx
pygments==2.18.0
# via sphinx
pyproject-api==1.6.1
# via tox
pyright==1.1.360
# via -r typing.txt
pytest==8.2.0
pyproject-hooks==1.1.0
# via
# -r tests.txt
# -r typing.txt
# build
# pip-tools
pytest==8.2.0
# via -r tests.in
pyyaml==6.0.1
# via pre-commit
requests==2.31.0
# via
# -r docs.txt
# sphinx
# via sphinx
sniffio==1.3.1
# via trio
snowballstemmer==2.2.0
# via
# -r docs.txt
# sphinx
# via sphinx
sortedcontainers==2.4.0
# via trio
sphinx==7.3.7
# via
# -r docs.txt
# -r docs.in
# pallets-sphinx-themes
# sphinx-issues
# sphinxcontrib-log-cabinet
sphinx-issues==4.1.0
# via -r docs.in
sphinxcontrib-applehelp==1.0.8
# via
# -r docs.txt
# sphinx
# via sphinx
sphinxcontrib-devhelp==1.0.6
# via
# -r docs.txt
# sphinx
# via sphinx
sphinxcontrib-htmlhelp==2.0.5
# via
# -r docs.txt
# sphinx
# via sphinx
sphinxcontrib-jsmath==1.0.1
# via
# -r docs.txt
# sphinx
# via sphinx
sphinxcontrib-log-cabinet==1.0.1
# via -r docs.txt
# via -r docs.in
sphinxcontrib-qthelp==1.0.7
# via
# -r docs.txt
# sphinx
# via sphinx
sphinxcontrib-serializinghtml==1.1.10
# via
# -r docs.txt
# sphinx
# via sphinx
toposort==1.10
# via pip-compile-multi
tox==4.15.0
# via -r dev.in
trio==0.25.0
# via -r tests.in
typing-extensions==4.11.0
# via
# -r typing.txt
# mypy
# via mypy
urllib3==2.2.1
# via
# -r docs.txt
# requests
virtualenv==20.26.0
# via requests
virtualenv==20.26.1
# via
# pre-commit
# tox
wheel==0.43.0
# via pip-tools

# The following packages are considered to be unsafe in a requirements file:
# pip
# setuptools
9 changes: 6 additions & 3 deletions requirements/docs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#
alabaster==0.7.16
# via sphinx
babel==2.14.0
babel==2.15.0
# via sphinx
certifi==2024.2.2
# via requests
Expand All @@ -18,7 +18,7 @@ idna==3.7
# via requests
imagesize==1.4.1
# via sphinx
jinja2==3.1.3
jinja2==3.1.4
# via sphinx
markupsafe==2.1.5
# via jinja2
Expand All @@ -28,7 +28,7 @@ packaging==24.0
# sphinx
pallets-sphinx-themes==2.1.3
# via -r docs.in
pygments==2.17.2
pygments==2.18.0
# via sphinx
requests==2.31.0
# via sphinx
Expand All @@ -38,7 +38,10 @@ sphinx==7.3.7
# via
# -r docs.in
# pallets-sphinx-themes
# sphinx-issues
# sphinxcontrib-log-cabinet
sphinx-issues==4.1.0
# via -r docs.in
sphinxcontrib-applehelp==1.0.8
# via sphinx
sphinxcontrib-devhelp==1.0.6
Expand Down
1 change: 1 addition & 0 deletions requirements/tests.in
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
pytest
trio
14 changes: 14 additions & 0 deletions requirements/tests.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,25 @@
#
# pip-compile tests.in
#
attrs==23.2.0
# via
# outcome
# trio
idna==3.7
# via trio
iniconfig==2.0.0
# via pytest
outcome==1.3.0.post0
# via trio
packaging==24.0
# via pytest
pluggy==1.5.0
# via pytest
pytest==8.2.0
# via -r tests.in
sniffio==1.3.1
# via trio
sortedcontainers==2.4.0
# via trio
trio==0.25.0
# via -r tests.in
2 changes: 2 additions & 0 deletions requirements/tests37.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
pytest
trio==0.22.2
Loading

0 comments on commit b002d9c

Please sign in to comment.