RocketChat / RocketChat/Rocket.Chat
Redirection of error page(Random route) to a setup wizard page
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Description:
A critical routing error has been identified where navigating to any invalid or non-existent URL (e.g., localhost:3000/random-path) fails to trigger a "404 Not Found" state. Instead, the application incorrectly defaults to the /setup-wizard route. This is a significant user experience issue and a potential security oversight, as the setup configuration should not be the fallback for dead links.
Steps to reproduce:
- Access the application: Open the browser and go to the main landing page (e.g., http://localhost:3000).
- Enter an invalid route: In the address bar, manually type a random string after the URL (e.g., http://localhost:3000/error-test-page).
- Trigger the bug: Press 'Enter' to navigate to that non-existent route.
- Observe: The browser will immediately redirect to the setup-wizard interface.
Expected behavior:
The application should recognize that the route does not exist and display a professional 404 Error Page. Following the standard of major websites like Amazon, it should clearly state: "Sorry, we couldn't find that page," and provide a prominent button to "Go to Home Page."
Actual behavior:
The application fails to provide an error state and instead moves the user directly into the Setup Wizard page, regardless of whether the system is already configured.
Server Setup Information:
-Version of Rocket.Chat Server: v8.0.1
-License Type:
-Number of Users: 1
-Operating System: Linux
-Deployment Method: Docker
-Number of Running Instances: 1
-DB Replicaset Oplog: Enabled
-NodeJS Version: 22.16.0
-MongoDB Version:
Client Setup Information
- Desktop App or Browser Version:
- Operating System:Windows 11
Additional context
Standard enterprise applications use a "Catch-All" route to manage invalid URLs. Redirecting to the Setup Wizard is misleading to the end-user, as it implies the server has lost its configuration or requires administrative action.
Relevant logs:
Client-side console observation:
Navigated to http://localhost:3000/invalid-route
Redirecting to http://localhost:3000/setup-wizard
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue by opening /invalid-route and confirm whether it redirects to /setup-wizard. Inspect the routing behavior around the setup-wizard entry point and the handling of unknown paths. Done means invalid URLs show a 404 page with a clear message and a way to return to the home page, without redirecting to setup.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend, web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100