Possible due to 625938a77f ("Move the code into a package (needed
for PEP 561)")
This is in order for tools to pick up injector type information while
analyzing client code.
If we want to distribute type information the right way and for the
tools to pick it up we need to follow PEP 561 and include a file named
py.typed. Unfortunately there's no way to include the file with
module-only distributions[1]:
This PEP does not support distributing typing information as part of
module-only distributions. The code should be refactored into
a package-based distribution and indicate that the package supports
typing as described above.
Therefore we need to have a package first - this is what this commit
does.
[1] https://www.python.org/dev/peps/pep-0561/#packaging-type-information
This doesn't provide much benefit to Injector itself but now
(Class)AssistedBuilder[T] and ProviderOf can be used in type hints[1]
like this:
class Class:
def __init__(self, builder: AssistedBuilder[OtherClass]):
# ...
By being able to do that projects using Injector will gain more static
type safety when tool like mypy is used to lint the code.
Python 2.6 support is dropped because the typing module requires Python
2.7 or newer.
[1] https://docs.python.org/3/library/typing.html