From 7a751e851511067d3510c81ea93cc01254484f33 Mon Sep 17 00:00:00 2001 From: David Vujic Date: Wed, 29 Oct 2025 21:55:23 +0100 Subject: [PATCH 1/3] fix: add missing build target packages entry in hatchling project template (i.e. applicable for uv and hatch) --- components/polylith/project/create.py | 5 ++++- components/polylith/project/get.py | 3 +++ test/components/polylith/project/test_templates.py | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/components/polylith/project/create.py b/components/polylith/project/create.py index 3629b4a1..be75b14d 100644 --- a/components/polylith/project/create.py +++ b/components/polylith/project/create.py @@ -1,7 +1,7 @@ from pathlib import Path import tomlkit -from polylith import repo +from polylith import configuration, repo from polylith.dirs import create_dir from polylith.repo import projects_dir @@ -21,6 +21,8 @@ def create_project(path: Path, template: str, name: str, description: str) -> No description_field = f'description = "{description}"' if description else "" authors_field = f"authors = {authors}" if authors else "" + namespace = configuration.get_namespace_from_config(path) + project_toml = create_project_toml( template, { @@ -28,6 +30,7 @@ def create_project(path: Path, template: str, name: str, description: str) -> No "description": description_field, "authors": authors_field, "python_version": python_version, + "namespace": namespace, }, ) diff --git a/components/polylith/project/get.py b/components/polylith/project/get.py index 9405faa6..555d7c7b 100644 --- a/components/polylith/project/get.py +++ b/components/polylith/project/get.py @@ -57,6 +57,9 @@ dependencies = [] +[tool.hatch.build.targets.wheel] +packages = ["{namespace}"] + [tool.hatch.build.hooks.polylith-bricks] [tool.polylith.bricks] diff --git a/test/components/polylith/project/test_templates.py b/test/components/polylith/project/test_templates.py index e2ed29d3..e7f024ed 100644 --- a/test/components/polylith/project/test_templates.py +++ b/test/components/polylith/project/test_templates.py @@ -11,6 +11,7 @@ "description": "", "authors": "", "python_version": "3.12", + "namespace": "unit_test", } From 4f3f0bfb7cfcb105904ab160a4b292124e016fed Mon Sep 17 00:00:00 2001 From: David Vujic Date: Wed, 29 Oct 2025 21:56:13 +0100 Subject: [PATCH 2/3] bump Poetry plugin to 1.42.3 --- projects/poetry_polylith_plugin/pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/poetry_polylith_plugin/pyproject.toml b/projects/poetry_polylith_plugin/pyproject.toml index bfb0f7b7..14bc9c77 100644 --- a/projects/poetry_polylith_plugin/pyproject.toml +++ b/projects/poetry_polylith_plugin/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "poetry-polylith-plugin" -version = "1.42.1" +version = "1.42.3" description = "A Poetry plugin that adds tooling support for the Polylith Architecture" authors = ["David Vujic"] homepage = "https://davidvujic.github.io/python-polylith-docs/" From 7cb27fa8b23dd10eef959ca99eac3a1faea8e78e Mon Sep 17 00:00:00 2001 From: David Vujic Date: Wed, 29 Oct 2025 21:56:38 +0100 Subject: [PATCH 3/3] bump CLI to 1.35.2 --- projects/polylith_cli/pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/polylith_cli/pyproject.toml b/projects/polylith_cli/pyproject.toml index 7a4bf45b..ccec90cf 100644 --- a/projects/polylith_cli/pyproject.toml +++ b/projects/polylith_cli/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "polylith-cli" -version = "1.35.1" +version = "1.35.2" description = "Python tooling support for the Polylith Architecture" authors = ['David Vujic'] homepage = "https://davidvujic.github.io/python-polylith-docs/"