An error occurred with your deployment #31966
Replies: 13 comments 15 replies
-
Hey! I think more information is going to be needed for someone to help solve your problem. Where are you deploying your Next app? What do the runtime and deployment logs say? Hoping are you calling the API and how are are the working routes receiving the request vs the broken routes? |
Beta Was this translation helpful? Give feedback.
-
This issue will be also created when you are api dint have res.send method . I was testing and forget to send the res back to client. |
Beta Was this translation helpful? Give feedback.
-
I'm facing the same issue. Any way to fix it? Re-deploying fixes the issue but after a few hours or a day the issue starts happening again! 🤕 |
Beta Was this translation helpful? Give feedback.
-
The 504 error suddenly occurs while the api worked with no problem before, and redeploying is not working for me :( |
Beta Was this translation helpful? Give feedback.
-
Yup, had the same issue with GPT API, implementing a vercel.json file at the root level definitely helped. https://vercel.com/docs/concepts/functions/serverless-functions#execution-timeout |
Beta Was this translation helpful? Give feedback.
-
In my case: (nodejs, typescript)
|
Beta Was this translation helpful? Give feedback.
-
Yesterday I had this same problem, and the only thing I did was to continue using Render, as that's where I did my first deployment (I'm a beginner). I followed these steps: https://render.com/docs/deploy-nextjs-app. For anyone doing the same, read about the version of Node.js that Render uses, and change the Node.js version if your application requires it: https://render.com/docs/node-version, as I got a mongoose error yesterday because I hadn't read it. ESPAÑOL Ayer tenía este mismo problema y lo unico que hice fue seguir utilizando render, ya que ahí hice mi primer deploy (Soy un principiante). Seguí los siguiente pasos: https://render.com/docs/deploy-nextjs-app . Para el que vaya a hacer lo mismo, lean sobre la version de node js que usa render y cambien la version de node js si su aplicación lo requiere: https://render.com/docs/node-version ya que ayer me dio error de mongoose por no haber leido. |
Beta Was this translation helpful? Give feedback.
-
I had the same issue. I changed from: export default async function handler(req: NextApiRequest, res: NextApiResponse) {
if (req.method == 'POST') {
axios.get(`${process.env.NEXT_PUBLIC_BASE_URL}/api/ANOTHER-ROUTE`)
}
} To: export default async function handler(req: NextApiRequest, res: NextApiResponse) {
if (req.method == 'POST') {
// db.query [...]
// Do database operations instead of fetching another local route
}
} The first API call triggers the first serverless function, which then triggeres another serveless funcion (since we are calling another route). That means we are using Cold Start Time + Execution Time of our second function in the short limit (15s in Vercel's hobby plan) of our first function. |
Beta Was this translation helpful? Give feedback.
-
I am using openai free trial and for me the error was mainly because the reponse time was more than 10s. |
Beta Was this translation helpful? Give feedback.
-
so? what's the answer of the question? |
Beta Was this translation helpful? Give feedback.
-
but in my case it still throwing error how can i update this function limit
to 60s
…On Sun, May 19, 2024 at 9:07 PM Jaya ***@***.***> wrote:
Yep, I use docker to deploy my Next.js app. Nowadays Vercel function limit
time increases to 60s, it should be enough for personal use.
—
Reply to this email directly, view it on GitHub
<#31966 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/A5RB5TQ3PSBDHU3O7NSDUKLZDDBJZAVCNFSM5JCKBYFKU5DIOJSWCZC7NNSXTOKENFZWG5LTONUW63SDN5WW2ZLOOQ5TSNBYHA3DIOA>
.
You are receiving this because you commented.Message ID: <vercel/next.
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
you can find more information in this page: What can I do about Vercel Functions timing out? |
Beta Was this translation helpful? Give feedback.
-
It works! Thanks a lot 😅
…On Mon, 20 May, 2024, 9:29 am Jaya, ***@***.***> wrote:
but in my case it still throwing error how can i update this function
limit to 60s
… <#m_4096744797826448937_>
On Sun, May 19, 2024 at 9:07 PM Jaya *@*.*> wrote: Yep, I use docker to
deploy my Next.js app. Nowadays Vercel function limit time increases to
60s, it should be enough for personal use. — Reply to this email directly,
view it on GitHub <#31966 (reply in thread)
<#31966 (reply in thread)>>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A5RB5TQ3PSBDHU3O7NSDUKLZDDBJZAVCNFSM5JCKBYFKU5DIOJSWCZC7NNSXTOKENFZWG5LTONUW63SDN5WW2ZLOOQ5TSNBYHA3DIOA
<https://github.com/notifications/unsubscribe-auth/A5RB5TQ3PSBDHU3O7NSDUKLZDDBJZAVCNFSM5JCKBYFKU5DIOJSWCZC7NNSXTOKENFZWG5LTONUW63SDN5WW2ZLOOQ5TSNBYHA3DIOA>
. You are receiving this because you commented.Message ID: <vercel/next. @.*
>
you can find more information in this page: What can I do about Vercel
Functions timing out?
<https://vercel.com/guides/what-can-i-do-about-vercel-serverless-functions-timing-out>
—
Reply to this email directly, view it on GitHub
<#31966 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/A5RB5TTRMHV2ZC3XDKXDNXTZDFYJPAVCNFSM5JCKBYFKU5DIOJSWCZC7NNSXTOKENFZWG5LTONUW63SDN5WW2ZLOOQ5TSNBZGIYTCOA>
.
You are receiving this because you commented.Message ID: <vercel/next.
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
I'm facing this error suddenly for almost all of my API calls.
Any idea why this might be happening?
It goes away after redeploying for some but then appears again after some time.
Beta Was this translation helpful? Give feedback.
All reactions