@sanzoghenzo correctly pointed out that a py.typed file alone wasn't
enough to get the typing working, we also need to move inflection into
a package.
I tested this by running ./.venv/bin/python setup.py sdist and installing the generated .tar.gz file into a blank project.
First attempt without the setup.py changes didn't work, but moving to a package did.
example error:
main.py:3:21: error: Argument 1 to "camelize" has incompatible type "bool"; expected
"str"
inflection.camelize(False)
^
Found 1 error in 1 file (checked 1 source file)
@sanzoghenzo correctly pointed out that a
py.typed
file alone wasn't enough to get the typing working, we also need to move inflection into a package.I tested this by running
./.venv/bin/python setup.py sdist
and installing the generated.tar.gz
file into a blank project. First attempt without the setup.py changes didn't work, but moving to a package did.example error:
fixes: https://github.com/jpvanhal/inflection/issues/49
rel: https://www.python.org/dev/peps/pep-0561/#packaging-type-information