Goal
Add the first buildable, installable, typed PyPI distribution for base_cli.
Background
The supplied review found no pyproject.toml, setup.cfg, or setup.py; base_cli.__version__ is undefined even though the repository VERSION is 1.7.0; the root license is not packaged; and no py.typed marker or package-level packaging metadata exists. The repository-level pytest.ini also assumes the monorepo layout. These gaps prevent a clean wheel/sdist install and make the package's supported Python contract implicit.
Depends on #1741, the package-name/license decision.
Scope
- Add a standards-based build backend and PEP 621 metadata for the
lib/python/base_cli package.
- Expose
base_cli.__version__ from the repository version contract and wire the build metadata through a dynamic version declaration.
- Declare the chosen package name, license, supported Python floor, runtime dependencies, optional test dependencies, project URLs, and package README.
- Add and include an empty
base_cli/py.typed marker so downstream type checkers consume inline annotations.
- Include the selected license file and other required package data in the sdist and wheel.
- Keep tests out of the runtime wheel unless a deliberate test-distribution policy is documented.
Acceptance Criteria
python -m build produces a valid sdist and wheel from a clean checkout.
- The built metadata matches the approved name/license decision and declares the actual minimum supported Python version (the code currently requires at least Python 3.9 unless the support policy is intentionally changed).
- A clean virtual environment can install the wheel and run
import base_cli; assert base_cli.__version__ == "1.7.0".
- The wheel contains
py.typed, the package README, and the selected license metadata/file.
- A minimal documented Click-based command can be imported and run from the installed distribution.
- The package does not depend on the monorepo's
cli/python, root pytest.ini, or checkout-only files at runtime.
Validation
python -m build
twine check dist/*
- Install the wheel into a fresh virtual environment and run import/version and minimal-command smoke tests.
- Inspect
unzip -l dist/*.whl and the sdist file list for package-data and test leakage.
git diff --check and the focused package tests.
Non-Goals
- Do not publish to PyPI from this issue; publication automation is tracked separately.
- Do not redesign the
base_cli API or Base command behavior.
- Do not change the license without resolving the package identity/license decision first.
Project Fields
- Priority: P1
- Size: M
- Area: Packaging
- Initiative: Adoption Polish
Agent Assignment
Human first for the build-backend and metadata contract; implementation can follow the identity/license decision.
Goal
Add the first buildable, installable, typed PyPI distribution for
base_cli.Background
The supplied review found no
pyproject.toml,setup.cfg, orsetup.py;base_cli.__version__is undefined even though the repositoryVERSIONis1.7.0; the root license is not packaged; and nopy.typedmarker or package-level packaging metadata exists. The repository-levelpytest.inialso assumes the monorepo layout. These gaps prevent a clean wheel/sdist install and make the package's supported Python contract implicit.Depends on #1741, the package-name/license decision.
Scope
lib/python/base_clipackage.base_cli.__version__from the repository version contract and wire the build metadata through a dynamic version declaration.base_cli/py.typedmarker so downstream type checkers consume inline annotations.Acceptance Criteria
python -m buildproduces a valid sdist and wheel from a clean checkout.import base_cli; assert base_cli.__version__ == "1.7.0".py.typed, the package README, and the selected license metadata/file.cli/python, rootpytest.ini, or checkout-only files at runtime.Validation
python -m buildtwine check dist/*unzip -l dist/*.whland the sdist file list for package-data and test leakage.git diff --checkand the focused package tests.Non-Goals
base_cliAPI or Base command behavior.Project Fields
Agent Assignment
Human first for the build-backend and metadata contract; implementation can follow the identity/license decision.