Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing py.typed file in the built distribution #94

Open
benverhees opened this issue Feb 13, 2025 · 0 comments
Open

Missing py.typed file in the built distribution #94

benverhees opened this issue Feb 13, 2025 · 0 comments

Comments

@benverhees
Copy link

benverhees commented Feb 13, 2025

Description

The py.typed file appears to be missing from the wheel distribution on PyPI, even though it's correctly configured in the project. This file is necessary to indicate that the package supports type checking.

Consequently, there are a lot of modules silencing their type checkers for isodate: Code search results for # type: ignore

Important

The py.typed file is correctly included in the wheel when building locally using python -m build, suggesting this might be related to the release process rather than the build configuration.

Current Setup

  • MANIFEST.in includes: include src/isodate/py.typed
  • py.typed exists in source: src/isodate/py.typed
  • Local builds include py.typed in the wheel

Steps to Reproduce

Install the latest version of isodate:

pip install isodate

Check for the presence of py.typed in the installed package:

from importlib import resources

print(resources.files("isodate").joinpath("py.typed").is_file())  # Returns False

Expected Behavior

The py.typed file should be present in the installed package.

Actual Behavior

The py.typed file is missing, which means type checkers won't recognize the package's type hints.

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

No branches or pull requests

1 participant