Skip to content

Commit ea1fb52

Browse files
authored
Feature/436 template use poetry 2.x (#438)
* Update template for new projects to poetry 2.x * Adapt template so new projects do not fail from lint errors
1 parent 24c6422 commit ea1fb52

File tree

3 files changed

+31
-24
lines changed

3 files changed

+31
-24
lines changed

doc/changes/unreleased.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@ permissions to be increased for specific jobs.
3232
* [#161](https://github.com/exasol/python-toolbox/issues/161): Added support for installing extras & not using a cache to the python-environment action
3333
* [#408](https://github.com/exasol/python-toolbox/issues/408): Added support for GitHub runners who do not per default have pipx to use the python-environment action
3434
* #433: Removed directory .html-documentation/.doctrees after creating documentation
35+
* #436: Updated template for new projects to poetry 2.x
3536

3637
## Bugfixes
3738

3839
* #428: Fixed detecting report coverage failures
40+
* #434: Adapted template so new projects do not fail from lint errors

project-template/cookiecutter.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
"pypi_package_name": "exasol-{{cookiecutter.repo_name}}",
66
"import_package": "exasol.{{cookiecutter.package_name}}",
77
"description": "",
8-
"autor_full_name": "",
9-
"autor_email": "",
8+
"author_full_name": "",
9+
"author_email": "",
1010
"project_short_tag": "",
1111
"python_version_min": "3.9",
1212
"license_year": "{% now 'utc', '%Y' %}",

project-template/{{cookiecutter.repo_name}}/pyproject.toml

Lines changed: 27 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,64 @@
1-
[build-system]
2-
requires = [
3-
"poetry>=1.0.0",
4-
]
5-
build-backend = "poetry.core.masonry.api"
6-
7-
[tool.poetry]
1+
[project]
82
name = "{{cookiecutter.pypi_package_name}}"
9-
packages = [
10-
{include = "exasol"},
11-
]
123
version = "0.1.0"
4+
requires-python = ">={{cookiecutter.python_version_min}},<4.0"
135
description = "{{cookiecutter.description}}"
14-
15-
license = "MIT"
16-
176
authors = [
18-
"{{cookiecutter.autor_full_name}} <{{cookiecutter.autor_email}}>"
7+
{name = "{{cookiecutter.author_full_name}}", email = "{{cookiecutter.author_email}}"},
198
]
20-
219
readme = "README.md"
10+
license = "MIT"
11+
keywords = ['exasol', '{{cookiecutter.package_name}}']
12+
dynamic = ["dependencies"]
2213

14+
[tool.poetry]
15+
requires-poetry = ">=2.1.0"
16+
packages = [
17+
{ include = "exasol" },
18+
]
19+
20+
[poetry.urls]
2321
repository = "https://github.com/exasol/{{cookiecutter.repo_name}}"
2422
homepage = "https://github.com/exasol/{{cookiecutter.repo_name}}"
2523

26-
keywords = ['exasol', '{{cookiecutter.package_name}}']
27-
2824
[tool.poetry.dependencies]
29-
python = ">={{cookiecutter.python_version_min}},<4.0"
3025

3126
[tool.poetry.group.dev.dependencies]
32-
exasol-toolbox = ">=0.12.0"
27+
exasol-toolbox = "^1.1.0"
28+
29+
[build-system]
30+
requires = ["poetry-core>=2.0.0"]
31+
build-backend = "poetry.core.masonry.api"
3332

3433
[tool.coverage.run]
34+
relative_files = true
3535
source = [
3636
"exasol",
3737
]
3838

3939
[tool.coverage.report]
4040
fail_under = 15
4141

42-
4342
[tool.black]
4443
line-length = 88
4544
verbose = false
4645
include = "\\.pyi?$"
4746

48-
4947
[tool.isort]
5048
profile = "black"
5149
force_grid_wrap = 2
5250

53-
5451
[tool.pylint.master]
5552
fail-under = 5.0
5653
output-format = "colorized,json:.lint.json,text:.lint.txt"
54+
ignore = [
55+
"noxfile.py",
56+
"noxconfig.py",
57+
"version.py",
58+
]
59+
ignore-paths = [
60+
".*/test/.*",
61+
]
5762

5863
[tool.pylint.format]
5964
max-line-length = 88

0 commit comments

Comments
 (0)