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

SCALAFMT_LINTER_RULES file does not exist #2115

Closed
tyvich opened this issue Nov 10, 2021 · 9 comments
Closed

SCALAFMT_LINTER_RULES file does not exist #2115

tyvich opened this issue Nov 10, 2021 · 9 comments
Labels
bug Something isn't working

Comments

@tyvich
Copy link

tyvich commented Nov 10, 2021

Describe the bug

It appears that the latest version of slim-latest pushed to docker-hub does not run properly throwing the following error:

2021-11-10 20:00:16 [FATAL]     -> SCALAFMT_LINTER_RULES rules file (/action/lib/.automation/.scalafmt.conf) doesn't exist. 

Expected behavior

Should be able to run the JSON linter without SCALA linter sideeffects

Steps to Reproduce

docker run
-e RUN_LOCAL=true
-e ACTIONS_RUNNER_DEBUG=true
-e ERROR_ON_MISSING_EXEC_BIT=true
-e MULTI_STATUS=false
-e VALIDATE_JSON=true
-v $(pwd):/tmp/lint
github/super-linter:slim-latest
-->

  1. Run the above command

Logs

2021-11-10 20:00:13 [INFO]    - Image Revision:[897185a4aa3dded15d11d1a83c3c0e48d9351bdd]
2021-11-10 20:00:13 [INFO]    - Image Version:[897185a4aa3dded15d11d1a83c3c0e48d9351bdd]
...
2021-11-10 20:00:16 [DEBUG]     -> Language rules file variable (RUBY_LINTER_RULES) value is:[/action/lib/.automation/.ruby-lint.yml]
2021-11-10 20:00:16 [DEBUG]     -> RUBY_LINTER_RULES rules file (/action/lib/.automation/.ruby-lint.yml) exists.
2021-11-10 20:00:16 [DEBUG]   Loading rules for SCALAFMT...
2021-11-10 20:00:16 [DEBUG]   Getting linter rules for SCALAFMT...
2021-11-10 20:00:16 [DEBUG]   Default rules location: /action/lib/.automation...
2021-11-10 20:00:16 [DEBUG]   Variable names for language file name: SCALAFMT_FILE_NAME, language linter rules: SCALAFMT_LINTER_RULES
2021-11-10 20:00:16 [DEBUG]   Initializing LANGUAGE_LINTER_RULES value to an empty string...
2021-11-10 20:00:16 [DEBUG]   SCALAFMT language rule file (.scalafmt.conf) has .scalafmt name and conf extension
2021-11-10 20:00:16 [DEBUG]   Initializing SECONDARY_FILE_NAME and SECONDARY_LANGUAGE_FILE_PATH...
2021-11-10 20:00:16 [DEBUG]   Checking if the user-provided:[.scalafmt.conf] and exists at:[/tmp/lint/.github/linters/.scalafmt.conf]
2021-11-10 20:00:16 [DEBUG]     -> Codebase does NOT have file:[/tmp/lint/.github/linters/.scalafmt.conf].
2021-11-10 20:00:16 [DEBUG]     -> Codebase does NOT have file:[/tmp/lint/.github/linters/.scalafmt.conf], nor the file:[], using Default rules at:[/action/lib/.automation/.scalafmt.conf]
2021-11-10 20:00:16 [DEBUG]     -> Language rules file variable (SCALAFMT_LINTER_RULES) value is:[/action/lib/.automation/.scalafmt.conf]
2021-11-10 20:00:16 [FATAL]     -> SCALAFMT_LINTER_RULES rules file (/action/lib/.automation/.scalafmt.conf) doesn't exist. Terminating...

Additional context

Started just an hour or two ago

@tyvich tyvich added the bug Something isn't working label Nov 10, 2021
@adamdmharvey
Copy link

@tallguyjenks
Copy link

i get the same thing and even explicitly deactivating that linter still results in an error:

image

image

@adamdmharvey
Copy link

Is it possible that PR just missed adding a "default" .scalafmt.conf file maybe to this folder? https://github.com/github/super-linter/tree/main/TEMPLATES

@adamdmharvey
Copy link

And yes, the workaround that is valid for me right now is replacing :latest with :v4.8.1:

$ docker run -e RUN_LOCAL=true -v myrepo:/tmp/lint github/super-linter:v4.8.1

@tyvich
Copy link
Author

tyvich commented Nov 10, 2021

That or it looks like a file could be placed here .github/linters/.scalafmt.conf

@spoelly
Copy link

spoelly commented Nov 11, 2021

And yes, the workaround that is valid for me right now is replacing :latest with :v4.8.1:

$ docker run -e RUN_LOCAL=true -v myrepo:/tmp/lint github/super-linter:v4.8.1

4.8.0 this should be ;) because 4.8.1 is the latest

@spoelly
Copy link

spoelly commented Nov 11, 2021

4.8.0 also gives this error :(

@admiralAwkbar
Copy link
Collaborator

just added the file and should be working in latest

will cut a release today

@admiralAwkbar
Copy link
Collaborator

Added and cut

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants