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

Fix building wheels with py.typed files #113

Closed
wants to merge 1 commit into from
Closed

Fix building wheels with py.typed files #113

wants to merge 1 commit into from

Conversation

srittau
Copy link
Contributor

@srittau srittau commented Nov 2, 2023

No description provided.

@srittau
Copy link
Contributor Author

srittau commented Nov 2, 2023

Currently, the integration tests fail, since py.typed is not recognized. I'm not sure, why the tests didn't flag this in #109. Cc @Avasam

@srittau srittau marked this pull request as draft November 2, 2023 17:08
@srittau
Copy link
Contributor Author

srittau commented Nov 2, 2023

I think the tests fail locally, because previous runs create py.typed, which subsequent runs then pick up. I'll investigate more.

@Avasam
Copy link
Contributor

Avasam commented Nov 2, 2023

I think we check for file extensions to only accept .pyi and .md found in typeshed.
But after running once, a py.typed is added, which is then seen on a second run because the run is not cleaned up locally (on CI it doesn't matter since it's a temporary clone of typeshed iirc)

Ironically I was manually cleaning up the extra folders and files locally between runs because I was testing the file/folder generation.

I see some potential solutions:

  1. We could allow py.typed in our check. But that will allow py.typed files to slip in typeshed's source. We may not want that?
  2. Add clean-up code. (probably a good idea to avoid further similar issues of polluting a local typeshed repo)
  3. Change how/where the physical py.typed file is generated

@srittau
Copy link
Contributor Author

srittau commented Nov 2, 2023

The main problem here is that the integration tests modify files outside the stub uploader directory and don't clean up. I'll open a separate issue.

@srittau srittau closed this Nov 2, 2023
@srittau srittau deleted the fix-build branch November 2, 2023 17:28
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