There should be a console message when a script is not run because it has type `application/javascript;version=1.8`

NEW
Unassigned

Status

()

Firefox
Developer Tools: Console
17 days ago
16 days ago

People

(Reporter: fitzgen, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Very confusing to debug this without any idea why the script is not being run, and not showing up inside the debugger source list, despite the netmonitor showing that it was fetched OK.
Do you know where in the platform the script is getting ignored?  We can use nsContentUtils::ReportToConsole from there to send a message to the console.
Flags: needinfo?(nfitzgerald)
Unfortunately, I don't. Maybe ask in #content?
Flags: needinfo?(nfitzgerald)
https://searchfox.org/mozilla-central/rev/84cea84b12145d752e50ddca6be5462c38510e35/dom/script/ScriptLoader.cpp#1272

Warning on all invalid script types is probably not OK; they're commonly used for webgl data and whatnot.

We could warn if the type starts with "application/javascript" though...

But what about "text/javascript; version=1.8"?

Also, no other browser has supported this for a while, if ever, so this would really be just about our own internal code?
(In reply to Boris Zbarsky [:bz] (no decent commit message means r-) from comment #3)
> Also, no other browser has supported this for a while, if ever, so this
> would really be just about our own internal code?

I also don't see any hits in-tree for "version=1.8": https://dxr.mozilla.org/mozilla-central/search?q=version%3D1.8&redirect=false. I know we used to have it but I guess they got rewritten.
Right, when we removed support for it.
FWIW I do see results on a github code search for "application/javascript;version=1.8" (and also 1.7) https://github.com/search?q=%22application%2Fjavascript%3Bversion%3D1.8%22&type=Code&utf8=%E2%9C%93
You need to log in before you can comment on or make changes to this bug.