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

Moving relevant files to use the future annotations import for 'in-class' return values #286

Merged
merged 3 commits into from
Nov 18, 2024

Conversation

emersodb
Copy link
Collaborator

PR Type

Other

Short Description

Clickup Ticket(s): Link

Really small PR moving us to a better practice with mypy when defining functions inside a class that return an instance of that class. Previously, there was a hacky way of doing this, but John J. found a better way a few months ago. Just getting around to propagating it.

Tests Added

N/A

Copy link
Collaborator

@fatemetkl fatemetkl left a comment

Choose a reason for hiding this comment

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

LGTM! :)

Copy link
Collaborator

@lotif lotif left a comment

Choose a reason for hiding this comment

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

Nice! I didn't know about that one, and always found super annoying to add the double quotes.

It looks like this feature will be incorporated into python 3.14, we just need to revisit it and remove the imports if/when we end up migrating to that version.

@emersodb emersodb merged commit 416e1c6 into main Nov 18, 2024
6 checks passed
@emersodb emersodb deleted the dbe/move_to_future_annotations branch November 18, 2024 18:30
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.

3 participants