-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
pylint_fail_under failing since pylint 2.12.0 #5405
Comments
Do not use -pylint-fail-under --fail_under 7.0 --rcfile=.pylintrc src
+pylint --fail-under=7.0 --rcfile=.pylintrc src |
@Pierre-Sassoulas Did not know about this. Seems like all of my CI/CD pipelines need an update. Thanks for your help! |
@Pierre-Sassoulas Sorry to bother you again, Still run_check (){
message="LOCATION: $repo_dir"
echo -e "\033[1;34mInfo: $message\033[0m"
message="CHECK: Checking with '$check_name'"
echo -e "\033[1;34mInfo: $message\033[0m"
pylint --fail-under=8.0 --rcfile=.pylintrc $repo_dir
if [ $? -eq 1 ]; then
message=$2
echo -e "\033[1;31mERROR: $message\033[0m";
exit 1
else
message="[PASSED] Passed $check_name checking."
echo -e "\033[1;32mOK: $message\033[0m"
exit 0
fi
} Output: ------------------------------------------------------------------
Your code has been rated at 7.76/10 (previous run: 7.76/10, +0.00)
OK: [PASSED] Passed pylint checking. |
@parvathirajan the exit code is not necessarily 1, it's a bit encoded exit code from 0 to 32 |
Oh Sorry! I felt really dumb here, Didn't read the word it's a bit encoded. tested it, and it's working as expected. Also, one more question if you don't mind me Like how we can do it with |
No problem :) The score is shown in the output by default |
Amazing Work! hats off, Thank you so much and I really appreciate your help. Will try to contribute in the future. :) |
Bug description
After updating Pylint to 2.12.1 (also tried 2.12.0) it seems that pylint_fail_under does not work properly anymore. After downgrading to 2.11.1 everything seemed to work as expected.
Configuration
No response
Command used
Pylint output
Expected behavior
Would expect the program to exit with proper exit code, without raising an exception.
Pylint version
OS / Environment
Windows 10 Enterprise
Additional dependencies
No response
The text was updated successfully, but these errors were encountered: