Skip to content

chore: add py.typed in compliance with PEP 561#27209

Closed
niqodea wants to merge 1 commit into
huggingface:mainfrom
niqodea:chore/add-pytyped
Closed

chore: add py.typed in compliance with PEP 561#27209
niqodea wants to merge 1 commit into
huggingface:mainfrom
niqodea:chore/add-pytyped

Conversation

@niqodea

@niqodea niqodea commented Nov 1, 2023

Copy link
Copy Markdown
Contributor

What does this PR do?

Analogously to what has been done in this PR for diffusers, do the same for transformers.

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you read the contributor guideline,
    Pull Request section?
  • Was this discussed/approved via a Github issue or the forum? Please add a link
    to it if that's the case.
  • Did you make sure to update the documentation with your changes? Here are the
    documentation guidelines, and
    here are tips on formatting docstrings.
  • Did you write any new necessary tests?

Who can review?

Anyone in the community is free to review the PR once the tests have passed.

@amyeroberts

Copy link
Copy Markdown
Contributor

Hi @niqodea, thanks for opening this PR!

Transformers doesn't officially support type checking in the library. Type annotations are used as documentation but we don't guarantee that they are consistent and checked across the repo. See: #18485

@niqodea

niqodea commented Nov 1, 2023

Copy link
Copy Markdown
Contributor Author

Ah, just noticed that there has already been an attempt to integrate py.typed previously (link). However, I currently don't see much complaining in my project as of now. Maybe we can try integrating it again? Feel free to close this otherwise.

@niqodea

niqodea commented Nov 1, 2023

Copy link
Copy Markdown
Contributor Author

@amyeroberts yep, makes sense. Thanks for your review!

@niqodea niqodea closed this Nov 1, 2023
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