$ aws s3 sync --delete s3://my-test-bucket/ /backup/my-test-bucket/
download failed: s3://my-test-bucket/item.208 to ../backup/my-test-bucket/item.208 [Errno 21] Is a directory
item.208 is a file in the source S3 bucket and a directory in the target local directory. The situation occured after we moved around some files in S3, including replacing a directory with a file with the same name. It caused our backups to stop running due to "[Errno 21] Is a directory". We would expect "s3 sync" with the "--delete" flag to be able to cope with such a situation.
$ aws --version
aws-cli/1.14.63 Python/2.7.13 Linux/4.9.0-6-amd64 botocore/1.9.16