I have been attempting to use cache-money on a new project and ran
into a major problem. Normally it seems to be working as advertised
but completely falls over when attempting to register a background
task with BJ. Here is the error:
NoMethodError (You have a nil object when you didn't expect it!
The error occurred while evaluating nil.repository):
bj (1.0.1) lib/bj/table.rb:240:in `get'
bj (1.0.1) lib/bj/table.rb:236:in `'
bj (1.0.1) lib/bj/runner.rb:61:in `tickle'
bj (1.0.1) lib/bj/api.rb:66:in `submit'
I have seen other posts that suggest using
'transaction_without_cache_transaction' or attempting to only enable
cache-money for certain models (instead of everything by default) but
neither provided an adequate solution to the problem.
It seems like this could be solved by either not including cache-money
into each model, or being able to pass the correct information (or
redefine it) for processes outside the normal rails app.
Any help would be greatly appreciated.