Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: TypeError: Cannot read properties of null (reading 'range') #17070

Closed
alilland opened this issue Apr 7, 2023 · 2 comments
Closed

Bug: TypeError: Cannot read properties of null (reading 'range') #17070

alilland opened this issue Apr 7, 2023 · 2 comments
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion bug ESLint is working incorrectly repro:needed

Comments

@alilland
Copy link

alilland commented Apr 7, 2023

Environment

Node version:
v16.15.0

npm version:
yarn 1.22.19

Local ESLint version:
v5.4.0

Global ESLint version:

Operating System:
Mac OS 13.3 - 2.4 GHz 8-Core Intel Core i9

Parser:
babel-eslint@10.1.0 (cant upgrade to @babel/eslint-parser without breaking changes)

What parser are you using?

Other

What did you do?

standard/standard#1898

See issue on Standard library

What did you expect to happen?

expected linting output

What actually happened?

$ /Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/.bin/standard
standard: Unexpected linter output:

TypeError: Cannot read properties of null (reading 'range')
    at SourceCode.getTokenBefore (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/token-store/index.js:303:18)
    at checkSpacingBefore (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/rules/template-curly-spacing.js:52:42)
    at TemplateElement (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/rules/template-curly-spacing.js:117:17)
    at /Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/util/safe-emitter.js:45:58
    at Array.forEach (<anonymous>)
    at Object.emit (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/util/safe-emitter.js:45:38)
    at NodeEventGenerator.applySelector (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/util/node-event-generator.js:251:26)
    at NodeEventGenerator.applySelectors (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/util/node-event-generator.js:280:22)
    at NodeEventGenerator.enterNode (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/util/node-event-generator.js:294:14)
    at CodePathAnalyzer.enterNode (/Users/aronlilland/Documents/dev/controlair/backbone-ui/applications/backbone/node_modules/eslint/lib/code-path-analysis/code-path-analyzer.js:632:23)
    ```

### Participation

- [ ] I am willing to submit a pull request for this issue.

### Additional comments

_No response_
@alilland alilland added bug ESLint is working incorrectly repro:needed labels Apr 7, 2023
@fasttime
Copy link
Member

fasttime commented Apr 8, 2023

Thanks for the issue @alilland. Your version of ESLint is no longer maintained. Have you tried to upgrade to the current version of ESLint 8?

@nzakas
Copy link
Member

nzakas commented Apr 18, 2023

Closing as this is an older version of ESLint and no further info provided.

@nzakas nzakas closed this as not planned Won't fix, can't repro, duplicate, stale Apr 18, 2023
@eslint-github-bot eslint-github-bot bot locked and limited conversation to collaborators Oct 16, 2023
@eslint-github-bot eslint-github-bot bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Oct 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion bug ESLint is working incorrectly repro:needed
Projects
Archived in project
Development

No branches or pull requests

3 participants