Merge pull request #179455 from SuperSandro2000/black

black: 22.3.0 -> 22.6.0

authored by Sandro and committed by GitHub 1db6fe6a d9def27d

+37 -23
+2 -3
pkgs/development/python-modules/black/default.nix
··· 9 9 , aiohttp-cors 10 10 , click 11 11 , colorama 12 - , dataclasses 13 12 , mypy-extensions 14 13 , pathspec 15 14 , parameterized ··· 23 22 24 23 buildPythonPackage rec { 25 24 pname = "black"; 26 - version = "22.3.0"; 25 + version = "22.6.0"; 27 26 28 27 disabled = pythonOlder "3.6"; 29 28 30 29 src = fetchPypi { 31 30 inherit pname version; 32 - hash = "sha256-NQILiIbAIs7ZKCtRtah1ttGrDDh7MaBluE23wzCFynk="; 31 + hash = "sha256-bG054ortN5rsQNocZUNMd9deZbtZoeHCg95UX7Tnxsk="; 33 32 }; 34 33 35 34 nativeBuildInputs = [ setuptools-scm ];
+2 -2
pkgs/development/python-modules/diagrams/default.nix
··· 2 2 , buildPythonPackage 3 3 , pythonOlder 4 4 , fetchFromGitHub 5 - , black 6 5 , jinja2 7 6 , poetry-core 8 7 , round ··· 38 37 patches = [ 39 38 # The build-system section is missing 40 39 ./build_poetry.patch 40 + ./remove-black-requirement.patch 41 41 ]; 42 42 43 43 checkInputs = [ pytestCheckHook ]; 44 44 45 45 # Despite living in 'tool.poetry.dependencies', 46 46 # these are only used at build time to process the image resource files 47 - nativeBuildInputs = [ black inkscape imagemagick jinja2 poetry-core round ]; 47 + nativeBuildInputs = [ inkscape imagemagick jinja2 poetry-core round ]; 48 48 49 49 propagatedBuildInputs = [ graphviz ]; 50 50
+24
pkgs/development/python-modules/diagrams/remove-black-requirement.patch
··· 1 + diff --git a/autogen.sh b/autogen.sh 2 + index acbcacb..1f60b83 100755 3 + --- a/autogen.sh 4 + +++ b/autogen.sh 5 + @@ -21,11 +21,6 @@ 6 + exit 1 7 + fi 8 + 9 + -if ! [ -x "$(command -v black)" ]; then 10 + - echo 'black is not installed' 11 + - exit 1 12 + -fi 13 + - 14 + # preprocess the resources 15 + for pvd in "${providers[@]}"; do 16 + # convert the svg to png for azure provider 17 + @@ -55,7 +50,3 @@ 18 + # Generate doc for custom module 19 + echo "generating the docs for custom" 20 + python -m scripts.generate "custom" 21 + - 22 + -# run black 23 + -echo "linting the all the diagram modules" 24 + -black "$app_root_dir"/**/*.py
+4 -8
pkgs/development/python-modules/papermill/default.nix
··· 15 15 , entrypoints 16 16 , tenacity 17 17 , futures ? null 18 - , black 19 18 , backports_tempfile 20 19 , isPy27 21 - , pytest 22 - , pytest-cov 20 + , pytestCheckHook 23 21 , pytest-mock 24 22 }: 25 23 ··· 46 44 requests 47 45 entrypoints 48 46 tenacity 49 - black 50 47 ] ++ lib.optionals isPy27 [ 51 48 futures 52 49 backports_tempfile 53 50 ]; 54 51 55 52 checkInputs = [ 56 - pytest 57 - pytest-cov 53 + pytestCheckHook 58 54 pytest-mock 59 55 ]; 60 56 61 - checkPhase = '' 62 - HOME=$(mktemp -d) pytest 57 + preCheck = '' 58 + export HOME=$(mktemp -d) 63 59 ''; 64 60 65 61 # the test suite depends on cloud resources azure/aws
-8
pkgs/development/python-modules/pulumi/default.nix
··· 13 13 14 14 15 15 # for tests 16 - , tox 17 16 , go 18 17 , pulumictl 19 - , bash 20 18 , pylint 21 19 , pytest 22 20 , pytest-timeout 23 - , coverage 24 - , black 25 21 , wheel 26 22 , pytest-asyncio 27 23 ··· 55 51 pulumi-bin 56 52 pulumictl 57 53 mypy 58 - bash 59 54 go 60 - tox 61 55 pytest 62 56 pytest-timeout 63 - coverage 64 57 pytest-asyncio 65 58 wheel 66 - black 67 59 ]; 68 60 69 61 sourceRoot="source/sdk/python/lib";
+5 -2
pkgs/development/python-modules/schema-salad/default.nix
··· 32 32 ]; 33 33 34 34 checkInputs = [ 35 - black 36 35 pytestCheckHook 37 - ]; 36 + ] ++ passthru.optional-dependencies.pycodegen; 38 37 39 38 disabledTests = [ 40 39 # Setup for these tests requires network access ··· 47 46 pythonImportsCheck = [ 48 47 "schema_salad" 49 48 ]; 49 + 50 + passthru.optional-dependencies = { 51 + pycodegen = [ black ]; 52 + }; 50 53 51 54 meta = with lib; { 52 55 description = "Semantic Annotations for Linked Avro Data";