aws-samples / pcluster-manager

Manage AWS ParallelCluster through an easy to use web interface
https://pcluster.cloud
Apache License 2.0
65 stars 27 forks source link

Display error page in case an unmatched route is hit #489

Closed tmscarla closed 1 year ago

tmscarla commented 1 year ago

Description

Currently, pointing to a non-existing page in PCUI returns an empty page, which can be confusing for customers.

This PR introduces a new error page template in PCUI that displays a clear message to the user indicating that an error has occurred, along with options for resolving the issue.

Changelog entry

How Has This Been Tested?

Screenshot 2023-01-18 at 23 04 35

PR Quality Checklist

In order to increase the likelihood of your contribution being accepted, please make sure you have read both the Contributing Guidelines and the Project Guidelines

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

mtfranchetto commented 1 year ago

@tmscarla issue: have you tried testing the frontend when served from the backend? Serving from the backend as a public folder differs from going to Next.js directly. If you try accessing a non-existing path on Flask at the moment you receive a 404 error, and the index.html is not served.

mendaomn commented 1 year ago

test: let's add an e2e for this case

tmscarla commented 1 year ago

test: let's add an e2e for this case

Consider it done :)

@tmscarla issue: have you tried testing the frontend when served from the backend? Serving from the backend as a public folder differs from going to Next.js directly. If you try accessing a non-existing path on Flask at the moment you receive a 404 error, and the index.html is not served.

Yes I checked following the instructions you provided and I can confirm that it works! 👍🏻