Skip to content

Keep the PyPI package small - #300

Merged
nsheff merged 1 commit into
masterfrom
dev
Nov 20, 2026
Merged

nsheff merged 1 commit into
masterfrom
dev

Conversation

@nsheff

@nsheff nsheff commented Nov 20, 2026

Copy link
Copy Markdown
Member

The bedhost package for PyPI included the whole website folder. If the website's installed packages were present, that made it over 100 MB, which is larger than PyPI accepts. The source package now holds only the Python code, tests, README, and license (about 0.6 MB).

Copilot AI balanced review requested due to automatic review settings November 20, 2026 21:53
@nsheff
nsheff merged commit 57d883a into master Nov 20, 2026
3 checks passed

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Excluding runtime-required docs/index.md and docs/changelog.md from the sdist causes the API’s /v1 landing route, including redirects from /, to return 404 when run from an unpacked sdist.

1 open issue
What changed in this PR

This PR reduces bedhost’s PyPI source distribution size by excluding unrelated repository content, especially the website and its installed dependencies.

Changes:

  • Adds a Hatch source-distribution allowlist for Python code, tests, README, and license.
File Description
pyproject.toml Restricts source-distribution contents with an explicit Hatch allowlist.

Review effort: Balanced

Comment thread pyproject.toml
Comment on lines +86 to +88
# Keep the website (ui/), deployment files, and docs out of the PyPI sdist.
[tool.hatch.build.targets.sdist]
include = ["/bedhost", "/tests", "/README.md", "/LICENSE.txt"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants