Create a gist now

Instantly share code, notes, and snippets.

Embed
/config/initializers/s3.rb:1:in `<top (required)>': uninitialized constant AWS (NameError) - AWS-S3 Gem not working Mac OS X Lion
# If you are facing such an Error while installing/working with the aws-s3 gem
# /config/initializers/s3.rb:1:in `<top (required)>': uninitialized constant AWS (NameError)
# try adding this to your Gemfile instead..
gem 'aws-s3', :require => 'aws/s3'
# I was having this issue on Mac OS X Lion with aws-s3 gem 0.6.2
@mcelaney

This comment has been minimized.

Show comment
Hide comment
@mcelaney

mcelaney Oct 26, 2011

Thanks so much for adding this...

Thanks so much for adding this...

@jasdeepsingh

This comment has been minimized.

Show comment
Hide comment
@jasdeepsingh

jasdeepsingh Oct 26, 2011

No problem Sir! Pleasure is mine!

Owner

jasdeepsingh commented Oct 26, 2011

No problem Sir! Pleasure is mine!

@toptierlabs

This comment has been minimized.

Show comment
Hide comment
@toptierlabs

toptierlabs Jan 25, 2012

Why is this?

Why is this?

@jasdeepsingh

This comment has been minimized.

Show comment
Hide comment
@jasdeepsingh

jasdeepsingh Jan 25, 2012

@toptierlabs: You mean why we get this error???

Owner

jasdeepsingh commented Jan 25, 2012

@toptierlabs: You mean why we get this error???

@toptierlabs

This comment has been minimized.

Show comment
Hide comment
@toptierlabs

toptierlabs Jan 25, 2012

Sorry, I mean why :require => 'aws/s3' fixes it?

Sorry, I mean why :require => 'aws/s3' fixes it?

@jasdeepsingh

This comment has been minimized.

Show comment
Hide comment
@jasdeepsingh

jasdeepsingh Jan 25, 2012

@toptierlabs: This is because the library names specified for this gem are different than the actual gem name... the line

:require => 'aws/s3'

just lets bundler know what files to include for this gem. Let me know if that clears your doubt? Thanks!

Owner

jasdeepsingh commented Jan 25, 2012

@toptierlabs: This is because the library names specified for this gem are different than the actual gem name... the line

:require => 'aws/s3'

just lets bundler know what files to include for this gem. Let me know if that clears your doubt? Thanks!

@toptierlabs

This comment has been minimized.

Show comment
Hide comment
@toptierlabs

toptierlabs Jan 25, 2012

It's clear! Thank you.

It's clear! Thank you.

@jasdeepsingh

This comment has been minimized.

Show comment
Hide comment
@jasdeepsingh

jasdeepsingh Jan 25, 2012

Owner

jasdeepsingh commented Jan 25, 2012

@leandro-a-silva

This comment has been minimized.

Show comment
Hide comment
@leandro-a-silva

leandro-a-silva Jun 17, 2012

Thanks!

Thanks!

@simonfranzen

This comment has been minimized.

Show comment
Hide comment
@simonfranzen

simonfranzen Mar 11, 2018

If some got to this thread in 2018 -> See this thread with the same problem. https://stackoverflow.com/a/49222325/1625253

If some got to this thread in 2018 -> See this thread with the same problem. https://stackoverflow.com/a/49222325/1625253

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment