Add type hints to `eth.tools.builder` modules
See original GitHub issueWhat is wrong?
The eth.tools.builder
module is not type hinted. This makes using it in the trinity
module not possible.
How can it be fixed
Add type hints.
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (8 by maintainers)
Top Results From Across the Web
Add type hints and expose them via PEP561 #1112 - GitHub
The web3.py library isn't written with type hints. This needs to be fixed by: Adding all missing type hints. Enforcing type checking in...
Read more >Python Type Hints: How to Gradually Add Types for Third ...
One place you can apply graduality with Mypy is in the type hints for third party packages. The default course of action is...
Read more >How do I type hint a method with the type of the enclosing class?
Enable experimentation with new type system PEPs before they are accepted and added to the typing module. Currently, typing-extensions officially supports ...
Read more >Python typing module - Use type checkers effectively
Type Hints / Type Annotations We can annotate a function to specify its return type and the types of its parameters. This informs...
Read more >Type hints - The Blue Book
Type hints are the Python native way to define the type of the objects in a program. Traditionally, the Python interpreter handles types...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This issue can be closed as it has been taken care of in #1420
@cburgdorf I added the hints for most of the functions, but I am still getting the same error when I do this.
mypy --follow-imports=silent --ignore-missing-imports --no-strict-optional --check-untyped-defs --disallow-incomplete-defs --disallow-untyped-defs --disallow-any-generics scripts/benchmark
The error is as follows
scripts/benchmark/utils/chain_plumbing.py:80 error: Cannot call function of unknown type
The error is still occurring even though I added the type hints. So I ran the following commandmypy --follow-imports=silent --ignore-missing-imports chain_plumbing.py
I got no error while doing the above command, but got the error only when executing the whole benchmarks altogether. Is there something that we could infer from this?