eslint-plugin-import-order-alphabetical
eslint-plugin-import-order-alphabetical copied to clipboard
Bug in eslint 7.22.0
In the version of eslint 7.22.0, has this bug:
AssertionError [ERR_ASSERTION]: Fix has invalid range: {
"range": [
null,
null
],
"text": "import { ListrTask } from 'listr2'\nimport fs from 'fs-extra'\n\n// const unzipBackup = (): ListrTask => ({\n// title: 'Unzip',\n// task: () => {\n// //\n// },\n// });\n//\n// export default unzipBackup;\nimport { ListrTask } from 'listr2'\nimport fs from 'fs-extra'\n\n// const unzipBackup = (): ListrTask => ({\n// title: 'Unzip',\n// task: () => {\n// //\n// },\n// });\n//\n// export default unzipBackup;\n"
}
at assertValidFix ([hidden]\node_modules\eslint\lib\linter\report-translator.js:125:9)
at normalizeFixes ([hidden]\node_modules\eslint\lib\linter\report-translator.js:200:5)
at [hidden]\node_modules\eslint\lib\linter\report-translator.js:364:49
at Object.report ([hidden]\node_modules\eslint\lib\linter\linter.js:920:41)
at fixOutOfOrder ([hidden]\node_modules\eslint-plugin-import-order-alphabetical\order.js:205:13)
at [hidden]\node_modules\eslint-plugin-import-order-alphabetical\order.js:264:5
at Array.forEach (<anonymous>)
at reportOutOfOrder ([hidden]\node_modules\eslint-plugin-import-order-alphabetical\order.js:260:14)
at makeOutOfOrderReport ([hidden]\node_modules\eslint-plugin-import-order-alphabetical\order.js:280:3)
at reportAndReset ([hidden]\node_modules\eslint-plugin-import-order-alphabetical\order.js:476:9)
Process finished with exit code -1
But with eslint 7.21.0 works perfect, I think the problem is in the fixer.
Node: 14.15.4 Yarn: 2.4.1