From: Michael Jeanson Date: Tue, 15 Aug 2023 18:29:22 +0000 (-0400) Subject: fix: running black on python 3.11 X-Git-Tag: v2.0.6~18 X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=commitdiff_plain;h=05bbb348cd4b10e423cab38028023a3b13203f5d fix: running black on python 3.11 Black 22.0 is incompatible with click >= 8.1 [1], pin it to a working version. Traceback (most recent call last): File ".pyenv/bin/black", line 8, in sys.exit(patched_main()) ^^^^^^^^^^^^^^ File ".pyenv/lib/python3.11/site-packages/black/__init__.py", line 6606, in patched_main patch_click() File ".pyenv/lib/python3.11/site-packages/black/__init__.py", line 6595, in patch_click from click import _unicodefun # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ImportError: cannot import name '_unicodefun' from 'click' (.pyenv/lib/python3.11/site-packages/click/__init__.py) [1] https://github.com/psf/black/issues/2964 Change-Id: I502f10e4cdedae4c431a243fc621fa10ab8bc5cf Signed-off-by: Michael Jeanson Reviewed-on: https://review.lttng.org/c/babeltrace/+/10604 Reviewed-by: Philippe Proulx Reviewed-on: https://review.lttng.org/c/babeltrace/+/10618 --- diff --git a/dev-requirements.txt b/dev-requirements.txt index 8a6bc811..ab152984 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -1,2 +1,4 @@ black == 20.8b1 flake8 >= 3.8 +# Required for black 22.0, it's broken with click >= 8.1 +click < 8.1