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

lighthouse-server - URLs missing from URL selection dropdown on comparison page #1082

Open
daniel-arthur-sas opened this issue Nov 7, 2024 · 0 comments

Comments

@daniel-arthur-sas
Copy link

daniel-arthur-sas commented Nov 7, 2024

Bug Description

Currently we are running lhci off of two URLs of the following format:

  1. http://example.com/app/index.html#/home
  2. http://example.com/app/index.html#/document/<document_id>

NOTE: I have made sure to add a urlReplacementPattern to account for differing document ids and can confirm that the <document_id> is being correctly replaced with a static placeholder. The issue im experiencing seems to be unrelated.

LHCI successfully generates reports for both URLs and uploads them to Lighthouse Server. However, when viewing the project dashboard, I am only presented with a single URL in the URL dropdown list of the report viewer. Opening the report for this URL appears to open a report for URL 2, meaning we can't access the report for URL 1.

The only available URL in the comparison page drop-down list is http://example.com/FooBar/index.html which does not match either URL 1 or 2. It would appear that the hash in the URL is causing this issue. Our web application uses hash-based routing and this is not something we will be able to change any time soon. It would appear that anything after the hash in the URL is omitted from the URL list that lighthouse-server's comparison page displays.

We have an additional admin application routed at /admin.html#/home and I can confirm that since the URL previous to the hash is different (admin.html vs index.html), lighthouse-server correctly shows the URL in the dropdown-list.

To Reproduce

Configure lighthouse-ci to collect and upload reports for two URLs that use hash-based routing e.g. /index.html#/foo and /index.html#/bar

Expected behavior

When I visit lighthouse-server, I should be able to see and select both URLS 1 and 2 in the available dropdown list of the report comparison page.

Environment:

  • OS: Windows
  • Browser: Version 130.0.6723.92
  • Version: "@lhci/cli": "0.14.0",
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

No branches or pull requests

1 participant