terricain / aioboto3

Wrapper to use boto3 resources with the aiobotocore async backend
Apache License 2.0
732 stars 75 forks source link

Allow to raise Exceptions in Callback (upload_fileobj) #239

Closed poul1x closed 2 years ago

poul1x commented 3 years ago

The current Callback use case it too narrow: just record upload progress. But It can be more broad. Raising exceptions from Callback can be used to implement limiting the file upload size (in upload_fileobj ). When exception is caught, abort the file upload and reraise it.

terricain commented 2 years ago

Would this work when using normal boto3? As mainly I want to try and remain compatible with that.

poul1x commented 2 years ago

Oh, it doesn't. Further discussion makes no sense