diff mbox series

[1/2] pyproject.toml: add setuptools to requires; fix project structure

Message ID 20260812194433.40594-1-chris.laplante@agilent.com
State New
Headers show
Series [1/2] pyproject.toml: add setuptools to requires; fix project structure | expand

Commit Message

chris.laplante@agilent.com Aug. 12, 2026, 7:44 p.m. UTC
From: Chris Laplante <chris.laplante@agilent.com>

setuptools is listed as the build backend but wasn't in 'requires'.

We also need to tell setuptools to look for our modules in 'lib' since otherwise
it chokes on our non-standard layout with:

[stderr]
      error: Multiple top-level packages discovered in a flat-layout: ['lib', 'conf', 'vendor', 'contrib', 'classes'].

With these changes, 'uv sync' works and IDEs such as PyCharm can
properly analyze the project.

Signed-off-by: Chris Laplante <chris.laplante@agilent.com>
---
 pyproject.toml | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/pyproject.toml b/pyproject.toml
index 93508d92e..886753f14 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,10 +1,17 @@ 
 [build-system]
-requires = []
+requires = ["setuptools>=64"]
 build-backend = "setuptools.build_meta"
 
 [project]
 name = "bitbake"
 version = "2.19.0"
+requires-python = ">= 3.9"
+
+[tool.setuptools]
+package-dir = {"" = "lib"}
+
+[tool.setuptools.packages.find]
+where = ["lib"]
 
 [tool.vendoring]
 destination = "lib/bb/_vendor"