-
Notifications
You must be signed in to change notification settings - Fork 589
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
[Dev] Make the decorators type aware #4782
base: master
Are you sure you want to change the base?
Conversation
I attempted a similar change about 3 months ago. Adding type hints to decorators exposed numerous previously hidden type errors in the functions being decorated (which Pylint was ignoring before). This caused a cascade of new Pylint errors across the codebase, which is why I put it on hold at that time. Note that some of these type checks might require a newer version of Pylint to handle properly. |
Yea... we should fix this. Those additional errors could cause issues failed to be detected like #4770 |
I also tried this in like november haha. We should 100% do this and fix all the problems, though! |
…kypilot into make-decorator-type-aware
@andylizf would you like to take over this PR if you got some time? |
Sure. Will take a look then. |
@Michaelvll By the way, I have another PR related to type issues that could use your review when you have some time. Would you be able to take a look at it? |
Fixes #4353
Note: this PR is mainly AI generated. Need to be refined.
Tested (run the relevant ones):
bash format.sh
pytest tests/test_smoke.py
pytest tests/test_smoke.py::test_fill_in_the_name
conda deactivate; bash -i tests/backward_compatibility_tests.sh