Skip to content

Added Type Annotations #49

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

Merged
merged 2 commits into from
Jun 27, 2022
Merged

Added Type Annotations #49

merged 2 commits into from
Jun 27, 2022

Conversation

isacben
Copy link

@isacben isacben commented Jun 23, 2022

Added type annotations to the Adafruit_CircuitPython_Display_Shapes library for issue #40

@isacben isacben mentioned this pull request Jun 23, 2022
21 tasks
Copy link

@FoamyGuy FoamyGuy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@isacben thanks for working on this!

I have a few changes to request, I tried to notate each with a seperate comment. But the main thing is fill and outline properties on many of the shape objects are allowed to be set to None so their type can be Optional[int] instead of just int

Those same properties are repeated a few times in some of the different shapes

@isacben
Copy link
Author

isacben commented Jun 24, 2022

Hi @FoamyGuy

Thank you very much for the feedback! I have corrected most issues locally. The only open issue is the one about the Sparkline (int vs float).

I will push the changes when that last part is solved. :)

Thank you!

@isacben isacben requested a review from FoamyGuy June 25, 2022 04:18
Copy link

@FoamyGuy FoamyGuy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Tested successfully with simpletest from this repo on PyPortal.

Thanks for working on this! @isacben

@FoamyGuy FoamyGuy merged commit e5495c3 into adafruit:main Jun 27, 2022
@isacben
Copy link
Author

isacben commented Jun 27, 2022

Thanks your your feedback, @FoamyGuy !

adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Jun 28, 2022
Updating https://github.com/adafruit/Adafruit_CircuitPython_NeoTre to 1.2.0 from 1.1.11:
  > Merge pull request adafruit/Adafruit_CircuitPython_NeoTre#17 from CedarGroveStudios/main

Updating https://github.com/adafruit/Adafruit_CircuitPython_Display_Shapes to 2.4.6 from 2.4.5:
  > Merge pull request adafruit/Adafruit_CircuitPython_Display_Shapes#49 from isacben/display-shapes-type-annotations
  > Removed duplicate-code from library pylint disable
@isacben isacben deleted the display-shapes-type-annotations branch July 23, 2022 21:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants