Skip to content

Commit 83240dd

Browse files
authored
Merge pull request #97 from smkent/python-3.12
Add and use Python 3.12 for releases, update Poetry to 1.6
2 parents 8f8cd1d + 66cd3af commit 83240dd

File tree

9 files changed

+845
-756
lines changed

9 files changed

+845
-756
lines changed

.github/workflows/cd.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ name: Release
44
env:
55
ENABLE_PYPI_PUBLISH: true
66
ENABLE_TEST_PYPI_PUBLISH: true
7-
RELEASE_PYTHON_VERSION: "3.11"
8-
RELEASE_POETRY_VERSION: "1.3"
7+
RELEASE_PYTHON_VERSION: "3.12"
8+
RELEASE_POETRY_VERSION: "1.6"
99

1010
on:
1111
push:

.github/workflows/ci.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,9 @@ jobs:
2424
- "3.9"
2525
- "3.10"
2626
- "3.11"
27+
- "3.12"
2728
poetry-version:
28-
- "1.3"
29+
- "1.6"
2930

3031
runs-on: ${{ matrix.os }}-latest
3132
steps:

cookie_python/manage/github.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ def find_pr(
3030
) -> Optional[PullRequest]:
3131
pulls = [
3232
pr
33-
for pr in repo.get_pulls(head=f"{self.username}:{head}", base=base)
33+
for pr in repo.get_pulls(
34+
head=f"{self.username}:{head}", base=base # noqa: E231
35+
)
3436
]
3537
if not pulls:
3638
return None

cookie_python/manage/repo.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def create_release(self, tag: str) -> None:
4848
print(f"Should create release {tag}")
4949
# PyGithub's repository create_tag_and_release() doesn't support
5050
# generate_release_notes
51-
self.repo._requester.requestJsonAndCheck( # type: ignore
51+
self.repo._requester.requestJsonAndCheck(
5252
"POST",
5353
f"/repos/{self.repo.full_name}/releases",
5454
input={

poetry.lock

Lines changed: 828 additions & 745 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/test_new_cookie.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,12 @@ def test_new_cookie_create(temp_dir: str) -> None:
3939
.strip()
4040
), "Untracked files present in template-rendered project"
4141

42+
# Verify cruft is up to date
43+
subprocess.check_call(["poetry", "run", "pip", "install", "toml"])
4244
subprocess.check_call(
4345
["poetry", "run", "cruft", "diff", "--exit-code"], cwd=project_dir
4446
)
47+
4548
# Install rendered project
4649
subprocess.check_call(["poetry", "install"], cwd=project_dir)
4750
# Run rendered project's tests

{{cookiecutter.project_name}}/.github/workflows/cd.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ name: Release
44
env:
55
ENABLE_PYPI_PUBLISH: {{ "true" if cookiecutter.enable_pypi_publish|lower == "yes" else "false" }}
66
ENABLE_TEST_PYPI_PUBLISH: {{ "true" if cookiecutter.enable_pypi_publish|lower == "yes" else "false" }}
7-
RELEASE_PYTHON_VERSION: "3.11"
8-
RELEASE_POETRY_VERSION: "1.3"
7+
RELEASE_PYTHON_VERSION: "3.12"
8+
RELEASE_POETRY_VERSION: "1.6"
99

1010
on:
1111
push:

{{cookiecutter.project_name}}/.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ jobs:
2323
- "3.8"
2424
- "3.9"
2525
- "3.10"
26-
- "3.11"
26+
- "3.12"
2727
poetry-version:
28-
- "1.3"
28+
- "1.6"
2929

3030
runs-on: ${{ "{{" }} matrix.os }}-latest
3131
steps:

{{cookiecutter.project_name}}/.github/workflows/container.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ name: Build
44
env:
55
REGISTRY: ghcr.io
66
IMAGE_NAME: ${{ "{{" }} github.repository }}
7-
RELEASE_PYTHON_VERSION: "3.11"
8-
RELEASE_POETRY_VERSION: "1.3"
7+
RELEASE_PYTHON_VERSION: "3.12"
8+
RELEASE_POETRY_VERSION: "1.6"
99

1010
on:
1111
pull_request:

0 commit comments

Comments
 (0)