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

Add type hints #322

Open
Terseus opened this issue Jun 19, 2023 · 2 comments
Open

Add type hints #322

Terseus opened this issue Jun 19, 2023 · 2 comments

Comments

@Terseus
Copy link

Terseus commented Jun 19, 2023

Right now, when using this library in any project which uses mypy, it gives the following error:

error: Skipping analyzing "m3u8": module is installed, but missing library stubs or py.typed marker

That's because the library doesn't have type hints, nor have type stubs in the typeshed repository.

Type hints are super helpful, not only can help to prevent bugs when combined with a static code analyzer like mypy, but also serves as documentation for any new user of the library, which makes it far easier to understand what can be and cannot be done with every method and property.

Please, consider adding type hints to the library.

@leandromoreira
Copy link
Contributor

Maybe we should introduce it as far as we go, meaning, for each new PR we should try to add type hint

@MichaelYochpaz
Copy link

Using mypy's stubgen tool might help speed-up the process and automate some of the work.

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

3 participants