-
Notifications
You must be signed in to change notification settings - Fork 1.2k
fix: use string annotations for S3Client type hints #4242
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
Conversation
mattf
left a comment
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.
we should avoid eval_str=True
s3/files.py uses future annotations while localfs/files.py does not.
do we need import __future__ import annotations for the s3 provider?
It seems like the import is there to allow mypy_boto3_s3 to be a dependency only when doing There are 2 alternative I can think of
|
i'm good with (1) if you are |
Remove future annotations import and use quoted string annotations for S3Client to avoid import issues. Changes: o Remove __future__ annotations import o Use "S3Client" string annotations in type hints Signed-off-by: Derek Higgins <[email protected]>
fe749c5 to
13fcf75
Compare
works for me, PR updated, thanks |
mattf
left a comment
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.
lgtm
ashwinb
left a comment
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.
lg
fix: use string annotations for S3Client type hints
closes: #4241