Annotate the library (add py.typed)#970
Conversation
|
This PR is not just about hash module, right? Also, what's missing for marking this ready for review? |
yeah there's refactor (and tightening) of mypy config and minor annotation fixes that result from that
possibly just fixing the PR message? |
* Move config to pyproject.toml * Turn on useful mypy options * Don't check tests with mypy: too much to fix right now * Add py.typed to announce this project is type annotated * Fix various annotation issues Issues remain in hash module Signed-off-by: Jussi Kukkonen <jkukkonen@google.com>
|
Only change in this force-push is that |
|
I will modify this so hash is left untouched by this PR: based on theupdateframework/python-tuf#2815 we can deprecate hash instead. |
This is useful since it will notice use of too new features (or lack of "from __future__ import annotations"). Signed-off-by: Jussi Kukkonen <jkukkonen@google.com>
Plan is to deprecate hash soon. Signed-off-by: Jussi Kukkonen <jkukkonen@google.com>
|
This should be good to go now. python-tuf lint (with this securesystemslib, with mypy excludes removed) has some complaints but only in tests and seemingly for good reason. |
I'd like to statically analyze calls to securesystemslib in other projects
Changelog: