Created
September 26, 2015 04:04
-
-
Save ch1ago/3345577befa1b5ec2b58 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
in this error, don't want to prepend main_app to every app-route. | |
this happens because the view template was loaded from an Engine controller | |
this is really annoying as it would force the end-developer to scope all of his app routes into main_app | |
9) Hello Gem Vision: Be a great Rails User Registration Open Source Library Goal: Authentication Capability: Email Sign In Feature: Single Form Context: Invalid Scenarios Scenario: Blank Password | |
Failure/Error: when_sign_in("foobar", "") | |
ActionView::Template::Error: | |
undefined local variable or method `users_path' for #<#<Class:0x007fcffb46cc88>:0x007fcffd182070> | |
# ./app/views/hello/shared/_nav_pills.html.erb:3:in `___sers_tj_github_hello_gem_hello_app_views_hello_shared__nav_pills_html_erb___3212978994574606722_70265653545820' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:145:in `block in render' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/activesupport/lib/active_support/notifications.rb:166:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:333:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:143:in `render' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/renderer/partial_renderer.rb:339:in `render_partial' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/renderer/partial_renderer.rb:310:in `block in render' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/renderer/abstract_renderer.rb:39:in `block in instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/activesupport/lib/active_support/notifications.rb:164:in `block in instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/activesupport/lib/active_support/notifications/instrumenter.rb:20:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/activesupport/lib/active_support/notifications.rb:164:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/renderer/abstract_renderer.rb:39:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/renderer/partial_renderer.rb:309:in `render' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/renderer/renderer.rb:47:in `render_partial' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/helpers/rendering_helper.rb:35:in `render' | |
# ./spec/dummy/app/views/layouts/application.html.erb:22:in `_app_views_layouts_application_html_erb___3946290121287052242_70265631018640' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:145:in `block in render' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/activesupport/lib/active_support/notifications.rb:166:in `instrument' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- before | |
<ul class="nav nav-pills pull-right"> | |
<li><%= link_to human_current_locale, hello.locale_path %></li> | |
<li><%#= link_to "User List", users_path %></li> | |
--now | |
<ul class="nav nav-pills pull-right"> | |
<li><%= link_to human_current_locale, locale_path %></li> | |
<li><%#= link_to "User List", main_app.users_path %></li> | |
now we get a different version of the same error. | |
we will unscope all paths within the gem hello | |
and only scope the app paths within main_app | |
however, when we try to load the view template on an App controller, | |
it doesn't recognize all of those methods from the engine hello. | |
Failure/Error: when_sign_in_with_standard_data(keep_me: true) | |
ActionView::Template::Error: | |
undefined local variable or method `locale_path' for #<#<Class:0x007faa14972028>:0x007faa18d2d9c0> | |
# ./app/views/hello/shared/_nav_pills.html.erb:2:in `___sers_tj_github_hello_gem_hello_app_views_hello_shared__nav_pills_html_erb___3618284488160606931_70184223134440' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:145:in `block in render' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/activesupport/lib/active_support/notifications.rb:166:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:333:in `instrument' | |
# /Users/tj/.rvm/gems/ruby-2.2.2/bundler/gems/rails-42b0c942520e/actionview/lib/action_view/template.rb:143:in `render' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
would you please help me solve this situation? | |
I have been working on this open source project for 18 months now and I am ready to make a release. | |
Thank you :) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment