Skip to content

Issues confirming emails #16

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

Closed
ChristienGuy opened this issue Jul 23, 2019 · 8 comments
Closed

Issues confirming emails #16

ChristienGuy opened this issue Jul 23, 2019 · 8 comments

Comments

@ChristienGuy
Copy link

As far as I understand it the hook handles email confirmation by default and it appears to be trying to but failing.

From what I can tell runRoutes correctly identifies the confirmation route and calls gotrue.confirm but somewhere within that call an error occurs.

The error logged is Error in confirm call JSONHTTPError: Failed to handle signup webhook.

@swyxio
Copy link
Contributor

swyxio commented Jul 23, 2019

thanks for the report. i've never seen that error before. it must come from lower down the stack. any thoughts on how to repro?

@ChristienGuy
Copy link
Author

Cheers for the reply! I managed to track down where this error is getting thrown here: https://github.com/netlify/gotrue/blob/master/api/hooks.go#L137

That said tho, I tried to repro it with a fresh netlify site and I can't seem to reproduce it, so it seems like it's an issue with the specific instance I'm trying to run it against.

I'll try my code against a fresh site later and see if I run into the same issue.

@ChristienGuy
Copy link
Author

It seems to have become resolved on the original site I was having trouble with.

I'm not totally sure what happened there but at least we know it wasn't an issue with this library, and it works so 🙌

@swyxio
Copy link
Contributor

swyxio commented Jul 23, 2019

weiiird

cheers

prs and docs welcome if you felt anything could be better of course. this is just something i'm doing on the side and doesnt get as much love as it ought to

@ChristienGuy
Copy link
Author

I think I've discovered the core of the problem! It was very much a me problem.

I had a serverless function identity-signup that was actually broken and I didn't realise that this function name essentially registers as a webhook (which makes sense when I stop and think about it).

So because that function was broken it was causing identity to break entirely when trying to singup and confirm emails.

@swyxio
Copy link
Contributor

swyxio commented Jul 23, 2019

ah.

btw we recently added netlify/netlify-dev-plugin#213 which helps with local test and development of serverless functions. havent done much publicity or stress testing yet but see if it helps you catch these sooner (in particular, intentionally write a broken function and then run netlify functions:invoke on it)

@meronek
Copy link

meronek commented Nov 3, 2019

I had the same "failed to handle signup webhook" error message suddenly appearing. It was after I had started messing with the identity-signup webhook. I added that function in my app, then deleted it, and that's when I started getting the error. I put the function back and now signupUser works again.

Just throwing this in here in case it helps someone else out.

@swyxio
Copy link
Contributor

swyxio commented Nov 3, 2019

file a new issue if it could be better, im not particularly working on this right now but i’ll take pr’s and repro cases

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

No branches or pull requests

3 participants