jmespath / jmespath.py

JMESPath is a query language for JSON.

Home Page:http://jmespath.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add type hints

and-semakin opened this issue · comments

Optional type hints allow static type checker (for example mypy, pyre, pyright, many IDEs) to check validity of code and allow Python programmers to write less buggy code. jmespath is one of the most popular libraries according to PyPI stats. I believe that adding type hints/annotations here will evolve entire Python ecosystem.

It can be added natively since Python 3.5 but also can be added in external stubs (*.pyi files) or commentaries (# type: int). Both methods will work with Python 2.7 and Python 3.4.

What do you think?