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
💅 Biome encountered an unexpected error when setting noExplicitAny=off in an override in CLI #1349
Comments
This should be fixed in the next release. |
Still getting this error in 1.5.1. Other disables work,
|
Got the same issue with "overrides": [
{
"include": ["*.spec.ts", "*.spec.tsx"],
"linter": {
"rules": {
"performance": {
"noDelete": "off"
}
}
}
}
] or even with an empty rules-object: "overrides": [
{
"include": ["*.spec.ts", "*.spec.tsx"],
"linter": {
"rules": {}
}
}
] We are using biome 1.5.2. I would like provide a playground reproduction but i don't found a way to define the config there. |
Use our Codesandbox template: https://codesandbox.io/p/sandbox/biome-starter-cbs-rky6zq |
Thank you! Here it is: https://codesandbox.io/p/devbox/divine-waterfall-wqglgc Just run Output
|
I ran into a similar issue, but instead I'm enabling a rule in an override. The rule is otherwise turned off. config{
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
"files": {
"ignore": [
"./.cache/**/*",
"./coverage/**/*",
"./node_modules/**/*",
"./translations/**/*"
]
},
"formatter": {
"ignore": ["*.ts", "*.tsx"],
"indentStyle": "space"
},
"json": {
"parser": {
"allowComments": true
}
},
"javascript": {
"formatter": {
"quoteStyle": "single",
"trailingComma": "none"
}
},
"linter": {
"rules": {
"recommended": false,
"a11y": {
"noAccessKey": "warn",
"noAriaHiddenOnFocusable": "warn",
"noAriaUnsupportedElements": "warn",
"noAutofocus": "off",
"noBlankTarget": "warn",
"noDistractingElements": "warn",
"noHeaderScope": "warn",
"noInteractiveElementToNoninteractiveRole": "warn",
"noNoninteractiveElementToInteractiveRole": "warn",
"noNoninteractiveTabindex": "off",
"noPositiveTabindex": "warn",
"noRedundantAlt": "warn",
"noRedundantRoles": "warn",
"noSvgWithoutTitle": "off",
"useAltText": "warn",
"useAnchorContent": "warn",
"useAriaActivedescendantWithTabindex": "warn",
"useAriaPropsForRole": "warn",
"useButtonType": "warn",
"useHeadingContent": "warn",
"useHtmlLang": "warn",
"useIframeTitle": "off",
"useKeyWithClickEvents": "off",
"useKeyWithMouseEvents": "warn",
"useMediaCaption": "off",
"useValidAnchor": "off",
"useValidAriaProps": "warn",
"useValidAriaRole": "warn",
"useValidAriaValues": "warn",
"useValidLang": "warn"
},
"complexity": {
"noBannedTypes": "warn",
"noExcessiveCognitiveComplexity": "off",
"noExtraBooleanCast": "warn",
"noForEach": "off",
"noMultipleSpacesInRegularExpressionLiterals": "warn",
"noStaticOnlyClass": "warn",
"noThisInStatic": "warn",
"noUselessCatch": "warn",
"noUselessConstructor": "warn",
"noUselessEmptyExport": "warn",
"noUselessFragments": "warn",
"noUselessLabel": "warn",
"noUselessRename": "warn",
"noUselessSwitchCase": "warn",
"noUselessThisAlias": "warn",
"noUselessTypeConstraint": "warn",
"noVoid": "warn",
"noWith": "warn",
"useArrowFunction": "warn",
"useFlatMap": "warn",
"useLiteralKeys": "warn",
"useOptionalChain": "warn",
"useRegexLiterals": "warn",
"useSimpleNumberKeys": "warn",
"useSimplifiedLogicExpression": "off"
},
"correctness": {
"noChildrenProp": "off",
"noConstAssign": "warn",
"noConstantCondition": "warn",
"noConstructorReturn": "warn",
"noEmptyCharacterClassInRegex": "warn",
"noEmptyPattern": "warn",
"noGlobalObjectCalls": "warn",
"noInnerDeclarations": "warn",
"noInvalidConstructorSuper": "warn",
"noInvalidNewBuiltin": "warn",
"noNewSymbol": "warn",
"noNonoctalDecimalEscape": "warn",
"noPrecisionLoss": "warn",
"noRenderReturnValue": "warn",
"noSelfAssign": "warn",
"noSetterReturn": "warn",
"noStringCaseMismatch": "warn",
"noSwitchDeclarations": "warn",
"noUndeclaredVariables": "off",
"noUnnecessaryContinue": "warn",
"noUnreachable": "warn",
"noUnreachableSuper": "warn",
"noUnsafeFinally": "warn",
"noUnsafeOptionalChaining": "warn",
"noUnusedLabels": "warn",
"noUnusedVariables": "off",
"noVoidElementsWithChildren": "warn",
"noVoidTypeReturn": "warn",
"useExhaustiveDependencies": "warn",
"useHookAtTopLevel": "warn",
"useIsNan": "warn",
"useValidForDirection": "warn",
"useYield": "warn"
},
"performance": {
"noAccumulatingSpread": "warn",
"noDelete": "warn"
},
"security": {
"noDangerouslySetInnerHtml": "warn",
"noDangerouslySetInnerHtmlWithChildren": "warn"
},
"style": {
"noArguments": "warn",
"noCommaOperator": "warn",
"noDefaultExport": "off",
"noImplicitBoolean": "off",
"noInferrableTypes": "warn",
"noNamespace": "warn",
"noNegationElse": "off",
"noNonNullAssertion": "off",
"noParameterAssign": "off",
"noParameterProperties": "warn",
"noRestrictedGlobals": "warn",
"noShoutyConstants": "warn",
"noUnusedTemplateLiteral": "warn",
"noUselessElse": "warn",
"noVar": "warn",
"useAsConstAssertion": "warn",
"useBlockStatements": "off",
"useCollapsedElseIf": "warn",
"useConst": "warn",
"useDefaultParameterLast": "off",
"useEnumInitializers": "warn",
"useExponentiationOperator": "warn",
"useFragmentSyntax": "warn",
"useLiteralEnumMembers": "warn",
"useNamingConvention": "off",
"useNumericLiterals": "warn",
"useSelfClosingElements": "warn",
"useShorthandArrayType": "warn",
"useShorthandAssign": "warn",
"useSingleCaseStatement": "off",
"useSingleVarDeclarator": "warn",
"useTemplate": "warn",
"useWhile": "warn"
},
"suspicious": {
"noApproximativeNumericConstant": "warn",
"noArrayIndexKey": "off",
"noAssignInExpressions": "off",
"noAsyncPromiseExecutor": "warn",
"noCatchAssign": "warn",
"noClassAssign": "warn",
"noCommentText": "warn",
"noCompareNegZero": "warn",
"noConfusingLabels": "warn",
"noConfusingVoidType": "warn",
"noConsoleLog": "warn",
"noConstEnum": "warn",
"noControlCharactersInRegex": "warn",
"noDebugger": "warn",
"noDoubleEquals": "warn",
"noDuplicateCase": "warn",
"noDuplicateClassMembers": "warn",
"noDuplicateJsxProps": "warn",
"noDuplicateObjectKeys": "warn",
"noDuplicateParameters": "warn",
"noEmptyInterface": "warn",
"noExplicitAny": "warn",
"noExtraNonNullAssertion": "warn",
"noFallthroughSwitchClause": "warn",
"noFunctionAssign": "warn",
"noGlobalIsFinite": "warn",
"noGlobalIsNan": "warn",
"noImplicitAnyLet": "off",
"noImportAssign": "warn",
"noLabelVar": "warn",
"noMisleadingInstantiator": "warn",
"noMisrefactoredShorthandAssign": "warn",
"noPrototypeBuiltins": "warn",
"noRedeclare": "warn",
"noRedundantUseStrict": "warn",
"noSelfCompare": "warn",
"noShadowRestrictedNames": "warn",
"noSparseArray": "warn",
"noUnsafeDeclarationMerging": "warn",
"noUnsafeNegation": "warn",
"useDefaultSwitchClauseLast": "warn",
"useGetterReturn": "warn",
"useIsArray": "warn",
"useNamespaceKeyword": "warn",
"useValidTypeof": "warn"
}
}
},
"organizeImports": {
"enabled": false
},
"overrides": [
{
"include": ["**/*.js"],
"linter": {
"rules": {
"suspicious": {
"noConsoleLog": "off"
}
}
}
},
{
"include": ["./src/path/**/*"],
"linter": {
"rules": {
"complexity": {
"noForEach": "warn"
}
}
}
}
]
} cli output
|
I am working on a fix that will be released at the start of next week. |
This should now be fixed by the last release: 1.5.3 |
Environment information
Rule name
noExplicitAny, but seems to happens with other rules when includes is used
Playground link
Expected result
No errors when running the CLI.
I get this:
Biome encountered an unexpected error
This is a bug in Biome, not an error in your code, and we would appreciate it if you could report it to https://github.com/biomejs/biome/issues/ along with the following information to help us fixing the issue:
Source Location: crates/biome_service/src/configuration/linter/mod.rs:167:18
Thread Name: biome::worker_6
Message: internal error: entered unreachable code: the rule is turned off, it should not step in here
Biome encountered an unexpected error
This is a bug in Biome, not an error in your code, and we would appreciate it if you could report it to https://github.com/biomejs/biome/issues/ along with the following information to help us fixing the issue:
Source Location: crates/biome_service/src/configuration/linter/mod.rs:167:18
Thread Name: biome::worker_1
Message: internal error: entered unreachable code: the rule is turned off, it should not step in here
./test/dev/devChildTask/dev-child-task.test.ts internalError/panic INTERNAL ━━━━━━━━━━━━━━━━━━━━━━
✖ processing panicked: internal error: entered unreachable code: the rule is turned off, it should not step in here
⚠ This diagnostic was derived from an internal Biome error. Potential bug, please report it if necessary.
Code of Conduct
The text was updated successfully, but these errors were encountered: