I have a rails app in development mode.
When I make changes to a ruby class called 'Dummy' under lib/dummy it doesn't get automatically reloaded, until I restart the rails server.
The class lives in a file under
lib/dummy/dummy.rb
class Dummy
def test
puts "XXX #{var_that_does_not_exist.stuff} XXX"
end
end
If I run this, the controller that calls
dummy = Dummy.new
dummy.test
causes an error as the variable 'var_that_does_not_exist' doesn't exist. If I updated the code to remove that variable, and make another request it continues to fail, until I actually restart the rails server.
development.rb contains
config.cache_classes = false
config.reload_classes_only_on_change = false
config.serve_static_assets = false
application.rb contains
# Autoload lib/ folder including all subdirectories
config.autoload_paths += Dir["#{config.root}/lib/**/"]
config.autoload_paths += Dir["#{config.root}/lib/duummy/"]