Closed ionmx closed 10 years ago
Have a stack?
here's our resque.rake
file in /lib/tasks/ if it helps (we use engines too but this is in the main one)
require 'resque/tasks'
require 'resque_scheduler/tasks'
require "resque_bus/tasks"
namespace :resque do
task :setup => [:environment] do
require 'resque_scheduler'
require 'resque/scheduler'
end
end
It's also possible you're doing this in development and this is the first time you've fully done an eager load, which preloads everything. That is to say, if your file names and paths a bit off, things might blow up.
Put another way, eager_load!
might blow up in the console too.
resque.rake
fixes the problem, thanks!
I'm trying to use resque-bus in an engine, but got "LoadError: No such file to load -- application_controller" when I try to run:
My task is located at my_app/engines/my_engine/lib/tasks/appB_subscriptions.rake
Which is the best way to achieve that?
ps. I've tried to fix it modifying resque: https://github.com/resque/resque/blob/master/lib/resque/tasks.rb#L38 but I guess you have a better way to do this.