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 support for Python 3.12 #515

Merged
merged 5 commits into from May 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Expand Up @@ -60,6 +60,7 @@ jobs:
- "3.9"
- "3.10"
- "3.11"
- "3.12"

steps:
- name: Get source code from pre-built sdist
Expand All @@ -71,6 +72,7 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
- run: python -Im pip install --upgrade wheel tox

- run: python -Im tox run -f py$(echo ${{ matrix.python-version }} | tr -d .)
Expand Down Expand Up @@ -136,6 +138,7 @@ jobs:
- "3.9"
- "3.10"
- "3.11"
- "3.12"

steps:
- name: Get source code from pre-built sdist
Expand All @@ -146,6 +149,7 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
- run: python -Im pip install --upgrade wheel tox

- run: python -Im tox -e mypy
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Expand Up @@ -15,6 +15,11 @@ You can find out backwards-compatibility policy [here](https://github.com/hynek/

## [Unreleased](https://github.com/hynek/structlog/compare/23.1.0...HEAD)

### Added

- Official support for Python 3.12.
[#515](https://github.com/hynek/structlog/issues/515)


## [23.1.0](https://github.com/hynek/structlog/compare/22.3.0...23.1.0) - 2023-04-06

Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Expand Up @@ -26,6 +26,7 @@ classifiers = [
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Programming Language :: Python",
Expand Down
3 changes: 3 additions & 0 deletions tests/test_generic.py
Expand Up @@ -7,6 +7,8 @@

import pytest

from freezegun import freeze_time

from structlog._config import _CONFIG
from structlog._generic import BoundLogger
from structlog.testing import ReturnLogger
Expand Down Expand Up @@ -52,6 +54,7 @@ def test_proxies_anything(self):
assert "gol", "bar" == b.gol("bar")

@pytest.mark.parametrize("proto", range(3, pickle.HIGHEST_PROTOCOL + 1))
@freeze_time("2023-05-22 17:00")
def test_pickle(self, proto):
"""
Can be pickled and unpickled.
Expand Down
1 change: 1 addition & 0 deletions tox.ini
Expand Up @@ -8,6 +8,7 @@ env_list =
py39{,-colorama},
py310,
py311{,-be,-rich},
py312,
docs,
coverage-report

Expand Down