Open
Bug 1936017
Opened 2 months ago
Updated 2 months ago
SyntaxErrors in editBookmark.js are incorrectly reported as being in places-menupopup.js
Categories
(Developer Infrastructure :: Lint and Formatting, defect)
Developer Infrastructure
Lint and Formatting
Tracking
(Not tracked)
NEW
People
(Reporter: tschuster, Unassigned, NeedInfo)
Details
After adding some invalid JS syntax like !!!
to editBookmark.js
running ./mach eslint
will report a SyntaxError in the wrong file.
An error occurred running eslint. Please check the following error messages:
Could not load globals from file /home/tom/projects/mozilla/browser/components/places/content/places-menupopup.js: SyntaxError: Unexpected token var
You may need to update the mappings for the browser-window environment
Oops! Something went wrong! :(
ESLint: 8.57.1
Error: Failed to load plugin 'mozilla' declared in '.eslintrc.js': Could not load globals from file /home/tom/projects/mozilla/browser/components/places/content/places-menupopup.js: SyntaxError: Unexpected token var
Referenced from: /home/tom/projects/mozilla/.eslintrc.js
at getGlobalsForScripts (/home/tom/projects/mozilla/tools/lint/eslint/eslint-plugin-mozilla/lib/environments/utils.js:36:13)
at getScriptGlobals (/home/tom/projects/mozilla/tools/lint/eslint/eslint-plugin-mozilla/lib/environments/utils.js:56:18)
at Object.<anonymous> (/home/tom/projects/mozilla/tools/lint/eslint/eslint-plugin-mozilla/lib/environments/browser-window.js:118:18)
at Module._compile (node:internal/modules/cjs/loader:1356:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1414:10)
at Module.load (node:internal/modules/cjs/loader:1197:32)
at Module._load (node:internal/modules/cjs/loader:1013:12)
at Module.require (node:internal/modules/cjs/loader:1225:19)
at require (node:internal/modules/helpers:177:18)
at Object.<anonymous> (/home/tom/projects/mozilla/tools/lint/eslint/eslint-plugin-mozilla/lib/index.js:22:23)
Unexpected type received
Traceback (most recent call last):
File "/home/tom/projects/mozilla/python/mozlint/mozlint/roller.py", line 83, in _run_worker
assert False
AssertionError
A failure occurred in the eslint linter.
✖ 1 problem (0 errors, 0 warnings, 1 failure, 0 fixed)
Comment 1•2 months ago
|
||
The severity field is not set for this bug.
:andi, could you have a look please?
For more information, please visit BugBot documentation.
Flags: needinfo?(bpostelnicu)
You need to log in
before you can comment on or make changes to this bug.
Description
•