You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The minimal repo I created did not have the bug. The bug happens in my repo cicero, branch eslint-issue, file ./src/grammar/grammarCategories.ts, line 19 ('Masculine/Feminine' = 'masculine/feminine', inside an enum). I have isolated this by running eslint against every .ts and .tsx file in the repo, and every enum in the relevant file - everything runs fine except for this file when this line is present.
Expected Result
When running eslint ./src/grammar/grammarCategories.ts, I expected eslint to check the file and list any errors it finds.
Actual Result
I get the following error, which removing the slash and the quotes around the key solves:
➜ cicero git:(main) ✗ eslint ./src/grammar/grammarCategories.ts
Oops! Something went wrong! :(
ESLint: 7.12.1
AssertionError [ERR_ASSERTION]: Node must be provided when reporting error if location is not provided
at assertValidNodeInfo (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/report-translator.js:98:9)
at /home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/report-translator.js:315:9
at Object.report (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/linter.js:920:41)
at Program:exit (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/rules/no-unused-vars.js:622:33)
at /home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/safe-emitter.js:45:58
at Array.forEach (<anonymous>)
at Object.emit (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/safe-emitter.js:45:38)
at NodeEventGenerator.applySelector (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/node-event-generator.js:254:26)
at NodeEventGenerator.applySelectors (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/node-event-generator.js:283:22)
at NodeEventGenerator.leaveNode (/home/bruno/code/projects/js/cicero/node_modules/.pnpm/[email protected]/node_modules/eslint/lib/linter/node-event-generator.js:306:14)
Repro
The minimal repo I created did not have the bug. The bug happens in my repo cicero, branch
eslint-issue
, file./src/grammar/grammarCategories.ts
, line 19 ('Masculine/Feminine' = 'masculine/feminine'
, inside an enum). I have isolated this by running eslint against every.ts
and.tsx
file in the repo, and every enum in the relevant file - everything runs fine except for this file when this line is present.Expected Result
When running
eslint ./src/grammar/grammarCategories.ts
, I expected eslint to check the file and list any errors it finds.Actual Result
I get the following error, which removing the slash and the quotes around the key solves:
Additional Info
Versions
@typescript-eslint/parser
4.6.1
TypeScript
3.9.7
ESLint
7.12.1
node
14.15.0
(TypeScript is not at the latest version because of this issue)
The text was updated successfully, but these errors were encountered: