Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Paperclip aws-sdk error: uninitialized constant

I'm currently running into the uninitialized constant Paperclip::Storage::S3::AWS error when I attempt to upload files to my server. I understand this to be typically caused by running an older version of paperclip, before they added support for aws-sdk-v2. The strange thing is that I'm running the latest paperclip version (4.3.1) which, according to its github page, includes aws-sdk-v2 support.

Honestly, I'm not sure what more I can say about this. I checked the error log and the above is the only complaint it has. Do I need to do anything special to run v2 with paperclip? Thanks to anyone who can shine any light onto this matter.

like image 858
neanderslob Avatar asked Dec 24 '22 13:12

neanderslob


1 Answers

the issue is written here:

http://ruby.awsblog.com/post/TxFKSK2QJE6RPZ/Upcoming-Stable-Release-of-AWS-SDK-for-Ruby-Version-2

try to change your Gemfile to:

  gem 'aws-sdk', '< 2.0'
like image 127
matanco Avatar answered Jan 05 '23 23:01

matanco