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

Rails.logger is undefined #27

Open
bsedat opened this issue Feb 15, 2012 · 2 comments
Open

Rails.logger is undefined #27

bsedat opened this issue Feb 15, 2012 · 2 comments

Comments

@bsedat
Copy link

bsedat commented Feb 15, 2012

It would be great if the Rails.logger was set/configurable within workers when running rails code. Right now we've seen other gems (specifically the DelayedJob gem) error out due to Rails.logger being undefined:

/mnt/sw_jobs/u9189/user_dir/gems/delayed_job/lib/delayed/worker.rb:22:in `<class:Worker>': undefined method `logger' for Rails:Module (NoMethodError)
from /mnt/sw_jobs/u9189/user_dir/gems/delayed_job/lib/delayed/worker.rb:8:in `<module:Delayed>'
from /mnt/sw_jobs/u9189/user_dir/gems/delayed_job/lib/delayed/worker.rb:7:in `<top (required)>'
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /mnt/sw_jobs/u9189/user_dir/gems/delayed_job/lib/delayed_job.rb:8:in `<top (required)>'
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /mnt/sw_jobs/u9189/user_dir/runner.rb:63:in `<main>'
@treeder
Copy link
Contributor

treeder commented Apr 11, 2012

Hey @bsedat-tinfoil , were you able to work around this?

And we're about to start pushing people towards our new ng gem that doesn't do all the Rails magic: https://github.com/iron-io/iron_worker_ruby_ng

@bsedat
Copy link
Author

bsedat commented Apr 11, 2012

We've worked around it but it would be convenience :)

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

No branches or pull requests

2 participants