-
-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Description
Tell us about your environment
- ESLint Version: 4.2.0
- Node Version: 6.9.2
- npm Version: 3.10.2
What parser (default, Babel-ESLint, etc.) are you using?
default
Please show your full configuration:
N/A
What did you do? Please include the actual source code causing the issue.
It seems that ESLint has upgraded its JSON validator for 4.2.0: #8852
Note: It's only a guess that the above change has caused the problems, but it's not fully confirmed.
This is causing issues for a rule in eslint-plugin-react:. It seems that the following schema validation is causing problems: https://github.com/yannickcr/eslint-plugin-react/blob/master/lib/rules/jsx-curly-spacing.js#L34
The produced error:
can't resolve reference #/definitions/basicConfig from id #
can't resolve reference #/definitions/basicConfigOrBoolean from id #
Warning: [object Object]:
Configuration for rule "react/jsx-curly-spacing" is invalid:
refVal[2] is not a function Use --force to continue.
at validateRuleOptions (node_modules\eslint\lib\config\config-validator.js:112:15)
at Object.keys.forEach.id (node_modules\eslint\lib\config\config-validator.js:152:9)
at Array.forEach (native)
at validateRules (node_modules\eslint\lib\config\config-validator.js:151:30)
at Object.validate (node_modules\eslint\lib\config\config-validator.js:206:5)
at runRuleForItem (node_modules\eslint\lib\testers\rule-tester.js:331:23)
at testValidTemplate (node_modules\eslint\lib\testers\rule-tester.js:413:28)
at Context.RuleTester.it (node_modules\eslint\lib\testers\rule-tester.js:546:25)
The issue can be reproduced by cloning the eslint-plugin-react repo and running npm run test.
What did you expect to happen?
No errors.
What actually happened? Please include the actual, raw output from ESLint.
See above.