-
-
Notifications
You must be signed in to change notification settings - Fork 686
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
Add type annotations, minor cleanups #2044
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a good cleanup; there's a minor tweak that can be made to the docstrings. The doctoring on app.py looks like it was historically wrong because it didn't have a type annotation.
8752aef
to
96f662f
Compare
96f662f
to
7b5ff67
Compare
FYI: The Linux CI failure will be fixed by #2052. The Android CI failure will be fixed by beeware/briefcase#1380. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for these improvements. I've made a couple of minor tweaks to wording and naming of the new protocols, but otherwise this looks great - and will make the task of rolling out the analogous changes to other widget classes a lot easier (as we now have a template to follow).
Out of interest - did you log the bug with Sphinx around the :rtype:
spelling error? I found a little more detail on this one - if you have any :param:
or :returns:
declaration, the "spelling error" goes away (e.g., adding a :param widget:
declaration to the OnPress handler fixes the spelling error with the None
return type.
Looks great, thank you! @freakboy3742 yes, I reported it here: sphinx-contrib/spelling#216 It seems to be caused by the autoprocol plugin. Won't have time to investigate it in the next days, though. |
Describe your changes in detail
typing.Protocol
s for callback functionsPR Checklist: