-
Notifications
You must be signed in to change notification settings - Fork 232
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Password Reset Implementation #11
Comments
I'll look into this right away. |
Can you post the code that you're using to send the password reset request? |
Ahh I see - it's trying to process the request as HTML:
It's rendering the default devise HTML form for some reason. Can you please post all the relevant configuration code? |
Yeah that's interesting. The code that I'm using to send the password reset request (same as your example configuration to keep things simple):
I reconfigured my environment to make sure I wasn't forgetting something simple, and kept all the configuration at the defaults. Not using the omniauth addon right now. It seems unrelated, but I configured CSRF protection per this SO post: http://stackoverflow.com/questions/7600347/rails-api-design-without-disabling-csrf-protection |
If i'm omitting some angular config you want to see, let me know. |
There are a couple of strange things here:
It looks like the |
In the process of reconfiguring my front-end environment to sort out this issue, bower install ng-token-auth resulted in:
just a heads up |
Yikes, looks like I pushed a bad tag. Deleting now. |
It's gone now. Thanks for the heads up. Also, thanks for bearing with with me thru all of these changes. I hope to release v1.0 within the next few days and things should be relatively stable from then on. |
I'm worried that this problem may have been caused by versioning issues. Can you please update both the rails gem and this module and see if the problem is solved? I just added one of those bower version badges to the README, hopefully I'll be less likely to screw up the versioning moving forward: Also, everything seems to be working on the demo app. It will always run the latest code - if you run into trouble, you can use that app for reference. |
I won't be able to verify this for a couple days but i'll check soon thanks lynn. |
not sure why, but all my requests are being processed as HTML even after the api and front-end env has been reconfigured. i guess you can close this issue unless someone else can recreate. |
@evbots - you mentioned that you're using CSRF. Have you tried disabling CSRF? |
yes i disabled CSRF as well |
@evbots - can you try to set the following in Devise.setup do |config|
config.navigational_formats = [:"*/*", "*/*", :json]
end |
I inspected the request/response headers, they look fine...but the server is still processing as HTML. I added your code to my initializer but the result is the same. My chrome inspect element output is below. What version of ruby are you using in development? I'm thinking it could maybe have something to do with the differences in angular version...you're using angular: "1.3.0-beta.11" and I am using 1.2.16 per the yo scaffold generator. Would you consider being explicit on the which angular version you're currently using on the ng-token-auth readme? I've been reading around and it looks like previous angular upgrades have caused http requests to break due to differences in request headers. Remote Address:127.0.0.1:3000 Request Headers Response Headers This example is from the registration endpoint, not reset password. Not a big deal because the problem is the same. |
@evbots - I'll try this out with angular v1.2, but both the request and response headers look fine - I have a feeling the problem is server-side. I don't think it's the ruby version either. I've tested on each version from 1.9.3 to 2.1.2, and I have travis running tests on both 1.9.3 and 2.1 with each push. I'm willing to take a look at your code. Can you grant me access to your repo? |
@evbots - Are you including any other libraries such as |
@evbots - I'm unable to reproduce this. I'm going to close the issue out - please re-open if the problem persists. |
Fix expiry data type
Having some trouble implementing the password reset. My form for the password reset form mirrors your example code. My event listener looks like...
That message isn't logged out to the console. The password reset state is set up properly in my routes. Looking at my server output, the parameters associated with the /auth/password POST request look like this...
As you can see, the params are getting passed in a second time under the password key. All my modules seem to be up to date. Any reason why password is included as a param? To clarify: The reset email is sending, but the event doesn't fire.
The text was updated successfully, but these errors were encountered: