Skip to content

Conversation

gruebel
Copy link
Contributor

@gruebel gruebel commented Mar 17, 2023

Great work on the package 💪

I saw you also added inline type hints, but didn't add the needed py.typed file to expose those type hints to type checkers. I also changed the setup call to use setuptools instead of distutils which will be removed in Python 3.12.

@gruebel
Copy link
Contributor Author

gruebel commented Mar 24, 2023

hey @moomoohk any chance for a review here 🙂

@moomoohk
Copy link
Collaborator

Hi Anton,
Much appreciated and apologies for the delay.
I'm on it.

@moomoohk
Copy link
Collaborator

Can you please provide a short explanation of the changes you've made?
From what I've read online this is related to Mypy, which I'm not too familiar with.

Thanks

@gruebel
Copy link
Contributor Author

gruebel commented Mar 25, 2023

yeah, sure.

This is related to the PEP 561 https://peps.python.org/pep-0561/

There are different ways of adding type hints to a Python code base, like stub files or inline type hints. The problem with inline type hints, I prefer inline type hints more than separate stub files, is that type checkers like mypy assume a package to be untyped, if it doesn't add a py.typed file in its package root.

@moomoohk moomoohk merged commit abb76a1 into dpath-maintainers:master Mar 25, 2023
@gruebel gruebel deleted the add-pytyped branch March 25, 2023 19:04
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