google / gts

☂️ TypeScript style guide, formatter, and linter.
https://github.com/google/gts
Apache License 2.0
5.09k stars 206 forks source link

gts lint fails after upgrading to node 22 #892

Closed mindrunner closed 1 month ago

mindrunner commented 3 months ago

works fine with node 20


ESLint: 8.57.0

AssertionError [ERR_ASSERTION]: Node must be provided when reporting error if location is not provided
    at assertValidNodeInfo (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/report-translator.js:83:9)
    at /home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/report-translator.js:333:9
    at Object.report (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/linter.js:1047:41)
    at Program (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint-plugin-prettier@5.1.3_eslint-config-prettier@9.1.0_eslint@8.57.0__eslint@8.57.0_prettier@3.2.5/node_modules/eslint-plugin-prettier/eslint-plugin-prettier.js:231:23)
    at ruleErrorHandler (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/linter.js:1076:28)
    at /home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/safe-emitter.js:45:58
    at Array.forEach (<anonymous>)
    at Object.emit (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/safe-emitter.js:45:38)
    at NodeEventGenerator.applySelector (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/node-event-generator.js:297:26)
    at NodeEventGenerator.applySelectors (/home/le/src/sa/account-uploader/node_modules/.pnpm/eslint@8.57.0/node_modules/eslint/lib/linter/node-event-generator.js:326:22)
 ELIFECYCLE  Command failed with exit code 1.
mindrunner commented 1 month ago

We had a config error in our prettier config.