Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose type data to other packages via PEP561 #1845

Conversation

@pipermerriam
Copy link
Member

commented Sep 5, 2019

What was wrong?

From a 3rd party library perspective, all of the values from py-evm are Any types.

How was it fixed?

Expose type information via PEP561

To-Do

  • Clean up commit history

Cute Animal Picture

ratsoff

@pipermerriam pipermerriam force-pushed the pipermerriam:piper/fix-missing-export-of-type-data branch from 3322241 to f9c0b7a Sep 5, 2019

@pipermerriam pipermerriam requested a review from cburgdorf Sep 5, 2019

@carver
carver approved these changes Sep 5, 2019
Copy link
Contributor

left a comment

Lol nice, do we get any fun mypy errors in trinity now?

@pipermerriam pipermerriam merged commit 939440a into ethereum:master Sep 5, 2019

20 checks passed

ci/circleci: py36-benchmark Your tests passed on CircleCI!
Details
ci/circleci: py36-core Your tests passed on CircleCI!
Details
ci/circleci: py36-database Your tests passed on CircleCI!
Details
ci/circleci: py36-docs Your tests passed on CircleCI!
Details
ci/circleci: py36-lint Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-byzantium Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-constantinople Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-frontier Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-homestead Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-petersburg Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-spurious_dragon Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-tangerine_whistle Your tests passed on CircleCI!
Details
ci/circleci: py36-native-blockchain-transition Your tests passed on CircleCI!
Details
ci/circleci: py36-transactions Your tests passed on CircleCI!
Details
ci/circleci: py36-vm Your tests passed on CircleCI!
Details
ci/circleci: py37-core Your tests passed on CircleCI!
Details
ci/circleci: py37-database Your tests passed on CircleCI!
Details
ci/circleci: py37-lint Your tests passed on CircleCI!
Details
ci/circleci: py37-transactions Your tests passed on CircleCI!
Details
ci/circleci: py37-vm Your tests passed on CircleCI!
Details
@pipermerriam

This comment has been minimized.

Copy link
Member Author

commented Sep 5, 2019

do we get any fun mypy errors in trinity now?

Yeah, I'm betting we get a lot

@pipermerriam pipermerriam deleted the pipermerriam:piper/fix-missing-export-of-type-data branch Sep 5, 2019

@cburgdorf

This comment has been minimized.

Copy link
Contributor

commented Sep 5, 2019

Uh, who would have thought we forgot about that haha

@pipermerriam

This comment has been minimized.

Copy link
Member Author

commented Sep 5, 2019

@cburgdorf I was thoroughly surprised. Took me a while to chase down why all these things were showing up as Any types.

@pipermerriam pipermerriam referenced this pull request Sep 5, 2019
2 of 2 tasks complete
@cburgdorf

This comment has been minimized.

Copy link
Contributor

commented Sep 6, 2019

Another thing contributing to Any are decorators. Those from eth_utils do already preserve type hints but stuff like @curry transforms a nicely typed method into an Any mess. We should reevaluate from time to time if we can increase some of the extra mypy checks to lead us out of Anyland.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.