Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Already initialized constant warnings #212

Closed
thomasfedb opened this issue Jan 2, 2016 · 4 comments
Closed

Already initialized constant warnings #212

thomasfedb opened this issue Jan 2, 2016 · 4 comments

Comments

@thomasfedb
Copy link

Hey, we use Fog::Aws in Carrierwave, and we've noticed some Ruby warning in our spec output that we've traced back to Fog::Aws, as follows:

/home/travis/.rvm/gems/jruby-1.7.19-d19/gems/fog-aws-0.7.6/lib/fog/aws/storage.rb:6 warning: already initialized constant COMPLIANT_BUCKET_NAMES
/home/travis/.rvm/gems/jruby-1.7.19-d19/gems/fog-aws-0.7.6/lib/fog/aws/storage.rb:8 warning: already initialized constant DEFAULT_REGION
/home/travis/.rvm/gems/jruby-1.7.19-d19/gems/fog-aws-0.7.6/lib/fog/aws/storage.rb:10 warning: already initialized constant DEFAULT_SCHEME
/home/travis/.rvm/gems/jruby-1.7.19-d19/gems/fog-aws-0.7.6/lib/fog/aws/storage.rb:11 warning: already initialized constant DEFAULT_SCHEME_PORT
/home/travis/.rvm/gems/jruby-1.7.19-d19/gems/fog-aws-0.7.6/lib/fog/aws/storage.rb:16 warning: already initialized constant VALID_QUERY_KEY

Would it be possible to get these resolved?

@geemus
Copy link
Member

geemus commented Jan 4, 2016

Hmm. Nothing obviously wrong in the storage file itself. Perhaps it is being required a second time. Is there any other stack/surrounding info you could share that might help me narrow down where that might be coming from?

@thomasfedb
Copy link
Author

Hey @geemus, this error occurs when we run our specs for carrierwave, and only occurs on JRuby. I haven't done a lot of investigation from our end yet.

There's no trace produced in the output, although I can probably set some JRuby flag to get a trace.

@geemus
Copy link
Member

geemus commented Jan 6, 2016

Got it. I'd be happy to fix it, just not sure where it is coming from. They are only defined the once, so I'm guessing the file gets required/loaded twice, but not certain.

@github-actions
Copy link

This issue has been marked inactive and will be closed if no further activity occurs.

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

No branches or pull requests

2 participants