From cd7b885169b5550019f68547e90913f75791ee96 Mon Sep 17 00:00:00 2001 From: Jeremy Reizenstein Date: Tue, 17 May 2022 09:08:06 -0700 Subject: [PATCH] don't check black version Summary: skip checking the version of black because `black --version` looks different in different versions. Reviewed By: kjchalup Differential Revision: D36441262 fbshipit-source-id: a2d9a5cad4f5433909fb85bc9a584e91a2b72601 --- dev/linter.sh | 12 ------------ setup.py | 2 +- 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/dev/linter.sh b/dev/linter.sh index b1d32c25..ae0892ba 100755 --- a/dev/linter.sh +++ b/dev/linter.sh @@ -7,18 +7,6 @@ # Run this script at project root by "./dev/linter.sh" before you commit -{ - V=$(black --version|cut '-d ' -f3) - code='import distutils.version; assert "19.3" < distutils.version.LooseVersion("'$V'")' - PYTHON=false - command -v python > /dev/null && PYTHON=python - command -v python3 > /dev/null && PYTHON=python3 - ${PYTHON} -c "${code}" 2> /dev/null -} || { - echo "Linter requires black 19.3b0 or higher!" - exit 1 -} - DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" DIR=$(dirname "${DIR}") diff --git a/setup.py b/setup.py index d4a0f94c..6b3f6800 100755 --- a/setup.py +++ b/setup.py @@ -143,7 +143,7 @@ setup( install_requires=["fvcore", "iopath"], extras_require={ "all": ["matplotlib", "tqdm>4.29.0", "imageio", "ipywidgets"], - "dev": ["flake8", "usort", "black==19.3b0"], + "dev": ["flake8", "usort", "black==22.3"], "implicitron": ["hydra-core>=1.1", "visdom", "lpips", "matplotlib"], }, entry_points={