Skip to content

Commit a83b530

Browse files
ueshinterana
authored andcommitted
[SPARK-56018][PYTHON][FOLLOW-UP] Disable black check by default
### What changes were proposed in this pull request? This is a follow-up of apache#54840. Disables black check by default. ### Why are the changes needed? The python formatter moved from `black` to `ruff` at apache#54840, but `lint-python` still runs the black check if no arguments are provided and there is `black` installed, causing many failures. ```sh % ./dev/lint-python starting python compilation test... python compilation succeeded. starting black test... black checks failed: ... ``` ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? N/A ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#54928 from ueshin/issues/SPARK-56018/disable_black. Authored-by: Takuya Ueshin <ueshin@databricks.com> Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
1 parent 8d500b8 commit a83b530

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

dev/lint-python

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function exit_with_usage {
3333
echo "lint-python - linter for Python"
3434
echo ""
3535
echo "usage:"
36-
cl_options="[--compile] [--black] [--custom-pyspark-error] [--ruff] [--mypy] [--mypy-examples] [--mypy-data]"
36+
cl_options="[--compile] [--custom-pyspark-error] [--ruff] [--mypy] [--mypy-examples] [--mypy-data]"
3737
echo "lint-python $cl_options"
3838
echo ""
3939
exit 1
@@ -74,9 +74,8 @@ while (( "$#" )); do
7474
shift
7575
done
7676

77-
if [[ -z "$COMPILE_TEST$PYSPARK_CUSTOM_ERRORS_CHECK_TEST$FLAKE8_TEST$RUFF_TEST$MYPY_TEST$MYPY_EXAMPLES_TEST$MYPY_DATA_TEST" ]]; then
77+
if [[ -z "$COMPILE_TEST$BLACK_TEST$PYSPARK_CUSTOM_ERRORS_CHECK_TEST$FLAKE8_TEST$RUFF_TEST$MYPY_TEST$MYPY_EXAMPLES_TEST$MYPY_DATA_TEST" ]]; then
7878
COMPILE_TEST=true
79-
BLACK_TEST=true
8079
PYSPARK_CUSTOM_ERRORS_CHECK_TEST=true
8180
RUFF_TEST=true
8281
MYPY_TEST=true

0 commit comments

Comments
 (0)