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

remove without-javascript audit #11459

Closed
GlenKPeterson opened this issue Sep 18, 2020 · 5 comments · Fixed by #11711
Closed

remove without-javascript audit #11459

GlenKPeterson opened this issue Sep 18, 2020 · 5 comments · Fixed by #11711

Comments

@GlenKPeterson
Copy link

My home page does not require JavaScript (except to start the service worker) and looks fine with it disabled. I added a <noscript> element and can see its text display, but the test doesn't care (probably because it doesn't run).

Provide the steps to reproduce

  1. Run LH on localhost - I'll upload the latest version to prod in the next few days and update this report.

What is the current behavior?

Test doesn't even run.

What is the expected behavior?

Test runs and passes

Environment Information

  • Affected Channels: Extension
  • Lighthouse version: 100.0.0.0
  • Chrome version: Google Chrome 85.0.4183.102 (Official Build) (64-bit)
    • Revision ffe848af6a5df4fa127e2929331116b7f9f1cb30-refs/branch-heads/4183@{Don't warn about blocking links with very short delays #1770}
    • OS Linux
    • JavaScript V8 8.5.210.20
    • Flash 32.0.0.433 /home/gpeterso/.config/google-chrome/PepperFlash/32.0.0.433/libpepflashplayer.so
    • User Agent Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.102 Safari/537.36
    • Command Line /usr/bin/google-chrome-stable --flag-switches-begin --flag-switches-end
  • Node.js version: NONE
  • Operating System: Ubuntu 18.04

Related issues
#11455 Failing this previous test may break some subsequent ones, IDK.

@patrickhulce
Copy link
Collaborator

Thanks for filing @GlenKPeterson! This is the same root issue as #11455. The without javascript test is the same page load as the HTTP redirect.

@patrickhulce patrickhulce changed the title Required HTMLWithoutJavaScript gatherer did not run Eliminate without-javascript audit's dependence on the HTTP redirect pass Sep 18, 2020
@patrickhulce
Copy link
Collaborator

For Lighthouse contributors, I propose just converting the without-javascript check to look for a <noscript> with some textContent. The check is so weak to begin with I doubt much would change and it would avoid this HTTP redirect issue.

@brendankenny
Copy link
Member

I propose just converting the without-javascript check to look for a <noscript> with some textContent

That does mean e.g. example.com (and any other completely static site) would fail the audit :/ I would guess that those are more common than sites not serving something on http (whether or not it's a redirect).

Another option worth considering is retiring the without-javascript audit in the next major release. No one has ever really expressed interest or ideas on how to make this obviously ham-fisted audit better and actually test what it claims to be doing. Maybe it's not worth keeping until (and if) some new approach is developed?

@patrickhulce
Copy link
Collaborator

patrickhulce commented Sep 18, 2020

That does mean e.g. example.com (and any other completely static site) would fail the audit :/ I would guess that those are more common than sites not serving something on http (whether or not it's a redirect).

Heh, so it would 🤦 I had some magical method in my head of "well of course we'd only do the noscript thing if there was enough script execution" but then deciding what's "enough" seems difficult (impossible?) and still eliminates gatsby-like situations that would've been fine. EDIT: Oh I remember my magical method! Use the MainResourceContent to find the textContent or noscript. :)

Ditching entirely sounds promising as well :)

@paulirish
Copy link
Member

We're going to delete the without-javascript audit for lighthouse v7

@paulirish paulirish changed the title Eliminate without-javascript audit's dependence on the HTTP redirect pass remove without-javascript audit Nov 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants