I start receiving this error from the past few days and it's failing a check. Any idea what's going wrong here?
Here are my env variables:
- name: Lint Code Base
uses: docker://github/super-linter:latest
env:
VALIDATE_ALL_CODEBASE: false
DEFAULT_BRANCH: development
JAVASCRIPT_ES_CONFIG_FILE: .eslintrc.json
VALIDATE_MD: false
VALIDATE_JAVASCRIPT_STANDARD: false
VALIDATE_JAVASCRIPT_ES: true
CI: true
2020-08-17 06:24:36 [INFO ] --------------------------------------------
2020-08-17 06:24:36 [INFO ] Gathering user validation information...
2020-08-17 06:24:36 [INFO ] - Only validating [new], or [edited] files in code base...
2020-08-17 06:24:36 [FATAL ] Behavior not supported, please either only include (VALIDATE=true) or exclude (VALIDATE=false) linters, but not both
@MuhaddiMu I believe this is by design. I can see from git history that enforcement of this behaviour was introduced as part of commit/d05f179506ba3d376680f8f2711712214bc75e99 to improve predictability of tests being run. @GaboFDC may be able to provide more information about this.
The behaviour is described the Environment Variables section of the primary readme, so please refer to this for more information.
If this worked previously, I suspect that was because this behaviour wasn't previously being enforced.
To resolve this, you could updated your VALIDATE_ variables to only specify the tests you want to either explicitly INCLUDE or EXCLUDE.
Assuming you only want to validate JavaScript ES, you should be able to use the following:
- name: Lint Code Base
uses: docker://github/super-linter:latest
env:
VALIDATE_ALL_CODEBASE: false
DEFAULT_BRANCH: development
JAVASCRIPT_ES_CONFIG_FILE: .eslintrc.json
VALIDATE_JAVASCRIPT_ES: true
CI: true
Hope this helps.
Thank you! That was helpful and resolve the error. I think this should be a warning instead of [Fatal] error.
@krowlandson was exactly right. This was changed to allow to only include some check or only exclude. This is a fatal because with the new logic we can not identify what is the expected behaviour. The config you had previously was redundant and was the same as only having VALIDATE_JAVASCRIPT_ES:聽true, so now, this is enforced.
Most helpful comment
@MuhaddiMu I believe this is by design. I can see from git history that enforcement of this behaviour was introduced as part of commit/d05f179506ba3d376680f8f2711712214bc75e99 to improve predictability of tests being run. @GaboFDC may be able to provide more information about this.
The behaviour is described the Environment Variables section of the primary readme, so please refer to this for more information.
If this worked previously, I suspect that was because this behaviour wasn't previously being enforced.
To resolve this, you could updated your
VALIDATE_variables to only specify the tests you want to either explicitlyINCLUDEorEXCLUDE.Assuming you only want to validate JavaScript ES, you should be able to use the following:
Hope this helps.