Skip to content

Commit

Permalink
Merge pull request #3195 from mroutis/fix-boto3-import
Browse files Browse the repository at this point in the history
s3: import boto3 inside _copy instead of module level
  • Loading branch information
efiop authored Jan 19, 2020
2 parents 7f5e4a9 + de1de68 commit 3c73e94
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dvc/remote/s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import logging
import os
import threading
from boto3.s3.transfer import TransferConfig

from funcy import cached_property, wrap_prop

Expand Down Expand Up @@ -157,6 +156,7 @@ def _copy(cls, s3, from_info, to_info, extra_args):
# the same throughout the transfer, so it means that in order to
# preserve etag, we need to transfer each part separately, so the
# object is transfered in the same chunks as it was originally.
from boto3.s3.transfer import TransferConfig

obj = cls.get_head_object(s3, from_info.bucket, from_info.path)
etag = obj["ETag"].strip('"')
Expand Down

0 comments on commit 3c73e94

Please sign in to comment.