You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to run the scenic generators in a Rails engine, but am getting an error.
Running rails g scenic:view test_report produces
/Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/scenic-1.4.0/lib/generators/scenic/view/view_generator.rb:77:in `views_directory_path': undefined method `join' for nil:NilClass (NoMethodError)
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/scenic-1.4.0/lib/generators/scenic/view/view_generator.rb:14:in `create_views_directory'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/command.rb:27:in `run'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/invocation.rb:126:in `invoke_command'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/invocation.rb:133:in `block in invoke_all'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/invocation.rb:133:in `each'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/invocation.rb:133:in `map'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/invocation.rb:133:in `invoke_all'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/group.rb:232:in `dispatch'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/thor-0.20.0/lib/thor/base.rb:466:in `start'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/railties-4.1.16/lib/rails/generators.rb:157:in `invoke'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/railties-4.1.16/lib/rails/commands/generate.rb:11:in `<top (required)>'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/railties-4.1.16/lib/rails/engine/commands.rb:19:in `require'
from /Users/developer/.rvm/gems/ruby-2.1.2@cs/gems/railties-4.1.16/lib/rails/engine/commands.rb:19:in `<top (required)>'
from bin/rails:12:in `require'
from bin/rails:12:in `<main>'
The text was updated successfully, but these errors were encountered:
I'm not certain what we can do about this one. It seems the way we're supposed to get the engine root is via EngineName::EngineClass.root but we don't know either of those. This isn't a feature I've ever wanted, so I'm not likely to spend much time chasing it down. @Epigene Is this something you'd be willing to spend some time on?
Nay, there is the additional problem of having to copy the view SQL files from engine to main app alongside engine migration files. I ended up writing a vanilla materialized view migration in engine.
Hi!
I am trying to run the scenic generators in a Rails engine, but am getting an error.
Running
rails g scenic:view test_report
producesThe text was updated successfully, but these errors were encountered: