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

no-constant-condition regression in v5.12.1 #11306

Closed
asapach opened this issue Jan 22, 2019 · 1 comment · Fixed by #11308, WealthWizardsEngineering/hpropagate#8 or DavidKindler/burger-builder#46 · May be fixed by jakeherp/burger-builder#11 or jakeherp/burger-builder#15
Labels
accepted There is consensus among the team that this change meets the criteria for inclusion archived due to age This issue has been archived; please open a new issue for any further discussion bug ESLint is working incorrectly rule Relates to ESLint's core rules

Comments

@asapach
Copy link

asapach commented Jan 22, 2019

Tell us about your environment

  • ESLint Version: v5.12.1
  • Node Version: v10.15.0
  • npm Version: v6.4.1

What parser (default, Babel-ESLint, etc.) are you using? default

Please show your full configuration:

Configuration
{
    "rules": {
        "no-constant-condition": 2
    }
}

What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint.

if ((foo || "bar") === "baz") {
   // fail
}

Demo

eslint test.js

What did you expect to happen?
No lint errors, same as in v5.12.0

What actually happened? Please include the actual, raw output from ESLint.
1:5 - Unexpected constant condition. (no-constant-condition)

It seems to be caused by #11253.

Are you willing to submit a pull request to fix this bug?
maybe

@asapach asapach added bug ESLint is working incorrectly triage An ESLint team member will look at this issue soon labels Jan 22, 2019
@not-an-aardvark
Copy link
Member

Thanks for the report, this looks like a bug to me.

@not-an-aardvark not-an-aardvark added rule Relates to ESLint's core rules accepted There is consensus among the team that this change meets the criteria for inclusion and removed triage An ESLint team member will look at this issue soon labels Jan 22, 2019
@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Aug 1, 2019
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Aug 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.