Closed NHLopez closed 2 months ago
Hi @NHLopez, Thanks for the report. I've run tests on my end, both on local copy and fresh clone, on both languages, and don't run into errors.
Could you please elaborate:
node version
Thanks.
Hey @BuckyBuck135,
Not sure what happened but it works now? I just cloned it fresh and now its fine.
Before. it would give that error whenever the page transitions. For example, if I do npm start the homepage showed up, when I clicked about, I would see the about page slightly then it would throw the above error so I thought it might be the transitions but when I looked on astros website it was fine.
Either way it works now so thank you so much. Just incase it happens again would you know anything I could do?
Ok great! Without being able to reproduce the bug, it's difficult to say where it was coming from. let's hope it doesn't crawl back up again! :)
Hi @BuckyBuck135, can we re-open this issue? I had exactly the same errors in my project, so I cloned it fresh and I'm able to reproduce this bug (without making any changes to "Advanced-Astro-v4-i18n" code). Only "npm install" and "npm run dev". Then clicking any navbar menu item (especially the same page as the current page) throws this error. Pressing "Reload" button (or manually entering URL) loads the page correctly again without any errors.
OS: Win 11 Pro 64-bit Node: v20.17.0
Let me know what other information I can provide.
Hi @netmaster2000, Thanks for your report. I've reopened the issue. I'm currently away for family reasons, so I won't have time to dig into this just now. In the meantime, if you do have some free time to run some debugging tests to try and pinpoint which page / component causes this issue, that would be a tremendous help.
After some quick tests, I looks like the issue does not impact the production site, which is good. I'll try to tackle this when I have some free time.
npm run build
+ npm run preview
shows you a copy of the deployed site on localhost.
You are right, the problem is only in "dev" mode. It looks like the i18n translations are not loaded on time. I'll try to debug it tomorrow.
I gave it a shot but couldn't figure it out. Something is wrong with "astrolicious/i18n", it is not loaded during the error, I don't know why. I tried to update it from your v0.4.3 to the latest 0.5.1, but it didn't help.
Hi guys, Thank you for your patience. I'm back at the keyboard after a family break.
The error seems to be coming from the custom 404 page. Short term: deleting this 404 page gets rid of the error.
Now, I'm working towards finding a more sustainable solution. I've opened an issue with the i18n package.
Hi everyone,
Since Astro patched the issue upstream with this PR, I reinstated the custom translated 404 route in the kit.
Make sure you upgrade Astro to at least v4.15.9, place 404.astro
in the routes/
folder and the matching translation in locales/
, as demonstrated in the kit.
Hey guys! I cloned the project and installed the dependencies and got this error. No changes were to the code. Something I thought was interesting was my first time installing the project it worked fine. After receiving this error and multiple times of cloning, installing, nothing will change. I had even thought it was the fact I upgraded to astro 4.12.3, but after just starting over I'm stuck.
I also noticed this:
Hopefully that helps, it was just something I noticed. Thank you!