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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[馃悶] Custom 404 page does not works #4399

Closed
keuller opened this issue Jun 2, 2023 · 2 comments
Closed

[馃悶] Custom 404 page does not works #4399

keuller opened this issue Jun 2, 2023 · 2 comments
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working

Comments

@keuller
Copy link
Contributor

keuller commented Jun 2, 2023

Which component is affected?

Qwik Runtime

Describe the bug

According to the documentation Custom 404 page we must create a file named 404.tsx inside src/routes folder. However, when we try to build the application pnpm build the process fails the following message:

[vite-plugin-qwik-city] Could not load /Users/keuller/workspace/personal/basic/@qwik-city-plan (imported by src/s_02wmimzeabk.js): More than one route has been found for pathname "/". Please narrow it down to only one of these:
  - /Users/keuller/workspace/personal/basic/src/routes/400.tsx
  - /Users/keuller/workspace/personal/basic/src/routes/index.tsx
error during build:
Error: Could not load /Users/keuller/workspace/personal/basic/@qwik-city-plan (imported by src/s_02wmimzeabk.js): More than one route has been found for pathname "/". Please narrow it down to only one of these:
  - /Users/keuller/workspace/personal/basic/src/routes/400.tsx
  - /Users/keuller/workspace/personal/basic/src/routes/index.tsx

Looks like the builder recognises 400.tsx file as a root file.

Reproduction

N/A

Steps to reproduce

Create a file named 400.tsx inside src/routes folder and try to run the application.

System Info

System:
    OS: macOS 13.4
    CPU: (10) arm64 Apple M1 Pro
    Memory: 16.00 GB
    Shell: /bin/zsh
  Binaries:
    Node: 18.16.0 - /usr/local/bin/node
    npm: 9.5.1 - /usr/local/bin/npm
  npmPackages:
    @builder.io/qwik: ^1.1.4 => 1.1.4
    @builder.io/qwik-city: ^1.1.4 => 1.1.4
    undici: 5.22.1 => 5.22.1
    vite: 4.3.5 => 4.3.5

Additional Information

No response

@keuller keuller added TYPE: bug Something isn't working STATUS-1: needs triage New issue which needs to be triaged labels Jun 2, 2023
@ehrencrona
Copy link
Contributor

The issue here seems to be a typo in the filename: it's supposed to be 404.tsx and not 400.tsx

@gioboa
Copy link
Member

gioboa commented Nov 20, 2023

@keuller can we close it?

@keuller keuller closed this as completed Nov 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants