You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've implemented a direct to s3 file upload mechanism, where the file first gets uploaded to the bucket root and then gets copied over to its final resting place using a copy command..
The copy fails if the file name has two spaces, as illustrated below -
1.9.3p484:052 > s3_object_1=artifact.attachment.bucket.objects.find("a b.pdf")=>#<S3::Object:/my-bucket/a b.pdf> 1.9.3p484:053 > s3_object_1.copy(:key=>"copy_of_file_1.pdf",:acl=>:private)S3::Error::SignatureDoesNotMatch: Therequestsignaturewecalculateddoes not matchthesignatureyouprovided.Checkyourkeyandsigningmethod.from/home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/connection.rb:217:in`handle_response' from /home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/connection.rb:204:in `send_request' from /home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/connection.rb:89:in `request'from/home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/service.rb:74:in`service_request' from /home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/bucket.rb:171:in `bucket_request' from /home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/object.rb:160:in `copy_object'from/home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/s3-0.3.11/lib/s3/object.rb:98:in`copy' from (irb):53 from /home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/railties-3.2.16/lib/rails/commands/console.rb:47:in `start' from /home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/railties-3.2.16/lib/rails/commands/console.rb:8:in `start'from/home/user_name/.rvm/gems/ruby-1.9.3-p484/gems/railties-3.2.16/lib/rails/commands.rb:41:in`<top (required)>' from script/rails:6:in `require' from script/rails:6:in `<main>'1.9.3p484:054 > s3_object_2=artifact.attachment.bucket.objects.find("x y.pdf")=>#<S3::Object:/my-bucket/x y.pdf> 1.9.3p484:055 > s3_object_2.copy(:key=>"copy_of_file_2.pdf",:acl=>:private)=>#<S3::Object:/my-bucket/copy_of_file_2.pdf>
The data setup is proper, "a b.pdf" (note doublespaces) and "x y.pdf" files exist in the same bucket as artifact.attachment ("artifact" is a rails active record object)
The text was updated successfully, but these errors were encountered:
I've implemented a direct to s3 file upload mechanism, where the file first gets uploaded to the bucket root and then gets copied over to its final resting place using a copy command..
The copy fails if the file name has two spaces, as illustrated below -
The data setup is proper, "a b.pdf" (note doublespaces) and "x y.pdf" files exist in the same bucket as artifact.attachment ("artifact" is a rails active record object)
The text was updated successfully, but these errors were encountered: