Closed kgutwin closed 1 year ago
+1, the same spurious Key
positional argument to upload_fileobj
is currently causing issues in our CI.
If it helps to isolate the issue, there were no problems with the previous environment containing: boto3-stubs==1.26.96
and mypy-boto3-s3==1.26.62
.
The problem appeared in my environment with boto3-stubs==1.26.97.post1
and mypy-boto3-s3==1.26.97
Thank you for the report. I will fix it today.
Fixed in mypy-boto3-s3 1.26.97.post2
. Please update and let me know if it works as it should.
PS. That was a rookie mistake >_< https://github.com/youtype/mypy_boto3_builder/commit/4dec4ac206c990fa968fc418b10f152839ddcdaf
Thank you so much for the fast attention, it’s much appreciated! Confirmed that it fixed the issue for me.
On Thu, Mar 23, 2023 at 11:50 AM Vlad Emelianov @.***> wrote:
Fixed in mypy-boto3-s3 1.26.97.post2. Please update and let me know if it works as it should.
PS. That was a rookie mistake :) 4dec4ac https://github.com/youtype/mypy_boto3_builder/commit/4dec4ac206c990fa968fc418b10f152839ddcdaf
— Reply to this email directly, view it on GitHub https://github.com/youtype/mypy_boto3_builder/issues/193#issuecomment-1481537800, or unsubscribe https://github.com/notifications/unsubscribe-auth/AE753UY3AMMA2XXFGAIQLDTW5R5NBANCNFSM6AAAAAAWFGYFPE . You are receiving this because you commented.Message ID: @.***>
@kgutwin please let me know if the issue is fixed for you.
Thanks for asking! I just switched back to the latest version and can confirm that it is working for me too.
Describe the bug Since mypy-boto3-builder 7.14.1 (at least), mypy-boto3-s3>=1.26.96 has been expecting a positional argument "Key" in the call to
upload_fileobj
on theObject
class. You can see this in the docs as follows:However, the "Key" argument is not required by this resource in boto3, as confirmed by the current AWS boto3 docs.
This issue also appears to affect several other methods of this class, such as
upload_file
,download_file
,download_fileobj
, andcopy
.This issue does not exist in mypy-boto-s3==1.26.62.
To Reproduce Steps to reproduce the behavior:
boto3-stubs[...]
mypy
/pyright
on the following code sampleActual output
Expected output
Additional context
boto3-stubs
installation method:pip install boto3-stubs[s3]>=1.26
Python version: 3.10.10