Welcome to the Kinde community.

P
K
A
A
A

Hello! When npm run build executes, it

Hello! When npm run build executes, it logs the error from my helper function yet it still builds successfully. I am assuming this is because it's only generating static pages so it can't fetch data. Is it okay to ignore these errors? If not, what is the correct way to handle this? Thanks!
Attachments
de0cefe7a317f5bb883b36361287bd37.png
9944f906c5fff67984b53cb4274fb2c0.png
D
g
P
4 comments
Hi, could you expand on what you're trying to do here. You say you're generating a static site, however you're referencing database code?
When I push my code to Vercel and it builds, I notice the build log mentions 'generating static pages'. To clarify, Iโ€™m not saying I'm generating a static site, but I'm referencing the message in the screenshot.

I also see the 'Error in specific user' log, which I understand is coming from my helper function. However, if that indicates the catch block was triggered, why is the build still successful?
I will ping this over to our nextjs expert who will be better placed to put some light on this for you.
Thanks for raising this @gitgy, i think its possible for Nextjs to build even when the trycatch catches an error.

To see more info on the error you can set KINDE_DEBUG_MODE=true in the .env file and then check the logs to see what is happening ๐Ÿ™‚
Add a reply
Sign up and join the conversation on Discord
Join