Open Bug 1667551 Opened 4 years ago Updated 2 years ago

Opening Style Editor while on Reddit causes hundreds of Launch Application requests for webpack links

Categories

(DevTools :: Style Editor, defect, P3)

Firefox 81
defect

Tracking

(Not tracked)

People

(Reporter: serhiy.int, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:80.0) Gecko/20100101 Firefox/80.0

Steps to reproduce:

F12 > F1 > Advanced settings > Enable browser chrome and add-on debugging toolboxes
And then switch to the Style Editor debug tab.

Actual results:

Firefox shows at least 300 requests for an application to open a webpack file.

Expected results:

Not this.

I'm trying to reproduce this issue but I'm having difficulties. Could you please provide more information from where exactly these 300 requests are displayed? Are you visiting any specific website?
Thanks.

Flags: needinfo?(serhiy.int)

I've just updated to 81.0 and it's no longer reproducible. Thank you, closing it.

Status: UNCONFIRMED → RESOLVED
Closed: 4 years ago
Flags: needinfo?(serhiy.int)
Resolution: --- → WORKSFORME

Wait, looks like it's not related to browser chrome debugging, it's on Reddit main and I'm still getting it. Should I create a new report or reopen this one?

You can just reopen this again.

Status: RESOLVED → UNCONFIRMED
Resolution: WORKSFORME → ---
Summary: "Enable browser chrome and add-on debugging toolboxes" causes hundreds of Launch Application requests for webpack links on opening Style Editor → Opening Style Editor while on Reddit causes hundreds of Launch Application requests for webpack links
Version: 80 Branch → Firefox 81

Here is how the requests look

Could you please provide another steps to reproduce since it's not related to browser chrome debugging?

Flags: needinfo?(serhiy.int)

Yes, of course:

  1. Load https://www.reddit.com
  2. Press F12 or Ctrl+Shift+I, open Style Editor tab.
Flags: needinfo?(serhiy.int)

Not sure about the expected behaviour. Assigning "DevTools: Style Editor" component.

Component: Untriaged → Style Editor
Product: Firefox → DevTools

@Hani: Thanks for the test case!

I can reproduce the problem on my machine. I am seeing 530 Stylesheets in the side bar.
Many of them showing: Error while fetching an original source: NetworkError when attempting to fetch resource.

Julian, can you please look at this?

Honza

Severity: -- → S3
Status: UNCONFIRMED → NEW
Has STR: --- → yes
Ever confirmed: true
Priority: -- → P3
Flags: needinfo?(jdescottes)

The website uses sourcemaps, but doesn't provide the original files on the production website. That's why you see many Error while fetching an original source errors. I believe the real problem is that on the logger's machine, when we attempt to download webpack:// urls, the OS doesn't know how to handle the link and displays a prompt.

For instance, the first internal style sheet is :

._33-F8KNeBDS4RS9mUMQdxH{color:var(--newRedditTheme-linkText)}

/*# sourceMappingURL=https://www.redditstatic.com/desktop2x/chunkCSS/AuthorHovercard~Governance~InFeedChaining~Reddit~SubredditHovercard~reddit-components-ClassicPost~re~2f1a95cc.37f54b40c7394dfef57f.css.map*/

If you attempt to download the specified sourcemap, it contains:

{ 
  "version": 3,
  "sources": [
    "webpack:///./src/reddit/components/Gold/AwardKarmaToastMessage/index.m.less"
  ],
  "names": [],
  "mappings": "AAAA,yBAAyB,qC",
  "file": "chunkCSS/AuthorHovercard~Governance~InFeedChaining~Reddit~SubredditHovercard~reddit-components-ClassicPost~re~2f1a95cc.37f54b40c7394dfef57f.css",
  "sourceRoot": ""
}

And webpack:///./src/reddit/components/Gold/AwardKarmaToastMessage/index.m.less is not accessible.
We can discuss about other ways to handle original files when sourcemaps are missing, but I don't think this is the original issue reported here.
We could file an enhancement to automatically bail out of sourcemaps if we can't fetch them, but I don't think this will help here, because the problem for the logger is with the request to a webpack:// URL.

I can reproduce the problem on my machine. I am seeing 530 Stylesheets in the side bar.

I think that the problem reported by the logger is rather about getting annoying "popups" to handle webpack:// links, and not about the styleeditor contents. I can't reproduce this on my machine, this might be linux only.

Note that you can disable "Show Original Sources" in the style editor to prevent the Style Editor from trying to fetch sourcemapped files.

Flags: needinfo?(jdescottes)

I just encountered this. It DoSed my machine, and caused kernel to go on a killing spree. I lost work.

See Also: → 1745386
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: