Closed Elindo586 closed 2 months ago
How long does it take for the email to be sent? It sounds like you might be hitting the default serverless execution limits, which can be configured via maxDuration
: https://vercel.com/docs/functions/configuring-functions/duration
If you're still running into troubles, I'd suggest opening a Vercel support ticket or community post, as GitHub issues are specifically for bugs or feature requests within the framework regardless of where it's hosted.
Thanks..
According to the Vercel information the max duration is already 15 seconds if I am reading it properly.
I also put it on the route.js to increase it to 10 according to the data you linked. Not sure if I am doing it properly.
Anyway, the error remains.
I have posted it on the community, but of course haven't gotten an answer and I am looking elsewhere, and I saw people with similar issues and didn't see an answer there either.
I will try to open a ticket at Vercel... . and wait... hopefully I get some feedback soon.
Thanks..
According to the Vercel information the max duration is already 15 seconds if I am reading it properly.
I also put it on the route.js to increase it to 10 according to the data you linked. Not sure if I am doing it properly.
Anyway, the error remains.
I have posted it on the community, but of course haven't gotten an answer and I am looking elsewhere, and I saw people with similar issues and didn't see an answer there either.
I will try to open a ticket at Vercel... . and wait... hopefully I get some feedback soon.
Can you clarify what the error is?
My goodness..
It works now? kind of, but for some reason it sends 3 emails instead of 1.
The code is the same, other than adding the timing that you suggested, but I tested it yesterday and didn't do anything either.
Suddenly, today, the page redirects and sent 3 emails instead of just 1.
The people from Vercel say they don't help at code level problems and just to ask the community, which I have asked, and searched for answers, and didn't find anything.
Anyway... since apparently the code is taking the actions it should, I will open another question in the community asking why would the code repeat the action of sending emails so many times.
I got to say, this is "weird" how the code seems to suddenly execute.
Ok... I found the real problem.
The href pointing to the route should have been like this: href="https://mysite
instead of href="https://www.mysite
^^^ for some reason adding the www didn't work.
Must have been something in the settings of the site at Vercel, or something from Godaddy... not sure, but I found the problem by accident when typing the route manually on the browser.
This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.
Link to the code that reproduces this issue
https://github.com/Elindo586/estuff/tree/main/app/my
To Reproduce
I am trying to do re-directs in two different ways.
^^ This code should work by clicking an external link directed to the site with the extension /my/othersocial/[link]/[email] The code works fine from my localhost, but not working on the live website as the page times out.
I have checked my environment variables and they are working OK.
Why is it that I am not able to get a re-direct?
I need to make sure to send an email with the information from the dynamic slugs, and then send the re-direction once the information for the email has been processed.
Current vs. Expected behavior
Current: Pages times out when visiting the live website, but it works fine from localhost
Expected: Once you visit the route from the live website, it should send an email telling me that variable ${email} has clicked a link, and then redirects the user to a proper website given from the variable ${link}
Provide environment information
Which area(s) are affected? (Select all that apply)
Developer Experience, Documentation, Middleware, Navigation, Pages Router, Runtime, Testing
Which stage(s) are affected? (Select all that apply)
Vercel (Deployed)
Additional context
The problem is when the site is uploaded to Vercel. It works fine from localhost.