Skip to content

Conversation

evanboho
Copy link

BUG:

  • in Rails 4.2, Devise goes into an infinite loop if relative_url_root is not set in the Rails config
  • when relative_url_root is set, Devise's test_helpers do not pass the attempted_url in the warden options
  • this causes an error at Pathname.new(attempted_path) in the failure_app

FIX:

  • add attempted_path to the warden options in the test_helpers

Versions:

  • Devise 3.5.6
  • Rails 4.1.13
  • Warden 1.2.6

BUG:
* in Rails 4.2, Devise goes into an infinite loop if relative_url_root is not set in the Rails config
* when relative_url_root is set, Devise's test_helpers do not pass the attempted_url in the warden options
* this causes an error at `Pathname.new(attempted_path)` in the failure_app
FIX:
* add attempted_path to the warden options in the test_helpers
@lucasmazza
Copy link
Contributor

@evanboho thanks a lot for the fix - any chance we can write a test case for this?

@ulissesalmeida
Copy link
Contributor

@evanboho Thank you for your report. Could please give more information in how to reproduce this bug?

In your description, you have mentioned about an infinite loop on Rails 4.2. But in the end of description you've mentioned the versions you tested was Devise 3.5.6 and Rails 4.1.13.

I've downloaded your branch, but your branch is running Devise 3.0.0.rc and Rails 4.0.0.rc1. I've uncommented the code you added and test suite is passing.

Could you please give us more information in how to reproduce it?

@ulissesalmeida ulissesalmeida added this to the 4.0.0 milestone Apr 11, 2016
@lucasmazza lucasmazza modified the milestone: 4.0.0 Apr 18, 2016
@ulissesalmeida
Copy link
Contributor

@evanboho I'm closing this PR. Feel free to reopen when you have more information in how to reproduce this issue, like a test case or a sample application for example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

3 participants