Skip to content
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

site: fix 404 page by upgrading SvelteKit and avoiding null reference #9337

Merged
merged 3 commits into from
Oct 23, 2023

Conversation

benmccann
Copy link
Member

will fix 404s sometimes being returned as 500s as discussed in #9116 (comment)

@benmccann benmccann requested a review from dummdidumm October 19, 2023 16:11
@changeset-bot
Copy link

changeset-bot bot commented Oct 19, 2023

⚠️ No Changeset found

Latest commit: ed30ebb

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@gtm-nayan
Copy link
Contributor

Houston, we have a problem

image

@benmccann
Copy link
Member Author

gah!! well we might as well upgrade anyway, but yeah it looks like we have something else to fix too

the lint failure is unrelated. I just sent another PR for that: #9338

@benmccann
Copy link
Member Author

I rebased this against master, so the CI is passing now. Let's go ahead and merge this just to be on the latest even if it doesn't fix the issue. We can also test in prod then to see if there was any weird caching going on in the Vercel preview environment or anything like that

@eltigerchino
Copy link
Member

eltigerchino commented Oct 20, 2023

Houston, we have a problem

image

Some thoughts on this issue sveltejs/kit#10565 (comment)
The main cause is a rendering error in the root +layout.svelte while rendering the default error page. #9344

{#if !$page.route.id.startsWith('/blog/')}

TypeError: Cannot read properties of null (reading 'startsWith')

but the error message being incorrect is a sveltekit issue

@benmccann
Copy link
Member Author

I sent sveltejs/kit#10911 to fix the types in SvelteKit.

And I pushed a commit here to allow the 404 page to render correctly: ed30ebb

@benmccann benmccann changed the title site: upgrade to SvelteKit 1.26.0 site: fix 404 page by upgrading SvelteKit and avoiding null reference Oct 23, 2023
@benmccann benmccann merged commit 3d20b39 into master Oct 23, 2023
6 checks passed
@benmccann benmccann deleted the kit-1.26 branch October 23, 2023 20:19
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

Successfully merging this pull request may close these issues.

4 participants