From 73cbe2bf78ef87fbf3ac55c34bc7c5515a1fdc00 Mon Sep 17 00:00:00 2001
From: Matt Liberty <mliberty@precisioninno.com>
Date: Thu, 11 Jul 2024 04:49:08 -0700
Subject: [PATCH] Update black to 24.3.0 to fix GH security alert (#2139)

Signed-off-by: Matt Liberty <mliberty@precisioninno.com>
---
 dependencies/includedyaml/__init__.py    |  1 +
 dependencies/includedyaml/constructor.py |  1 +
 dependencies/includedyaml/emitter.py     |  6 +++---
 dependencies/tool.py                     | 14 ++++++++------
 requirements_lint.txt                    |  2 +-
 5 files changed, 14 insertions(+), 10 deletions(-)

diff --git a/dependencies/includedyaml/__init__.py b/dependencies/includedyaml/__init__.py
index 9bd754e9a..3ab3c4649 100644
--- a/dependencies/includedyaml/__init__.py
+++ b/dependencies/includedyaml/__init__.py
@@ -17,6 +17,7 @@
 
 import io
 
+
 # ------------------------------------------------------------------------------
 # XXX "Warnings control" is now deprecated. Leaving in the API function to not
 # break code that uses it.
diff --git a/dependencies/includedyaml/constructor.py b/dependencies/includedyaml/constructor.py
index 1de226faf..e7514be94 100644
--- a/dependencies/includedyaml/constructor.py
+++ b/dependencies/includedyaml/constructor.py
@@ -856,6 +856,7 @@ def set_python_instance_state(self, instance, state):
     UnsafeConstructor.construct_python_object_apply,
 )
 
+
 # Constructor is same as UnsafeConstructor. Need to leave this in place in case
 # people have extended it directly.
 class Constructor(UnsafeConstructor):
diff --git a/dependencies/includedyaml/emitter.py b/dependencies/includedyaml/emitter.py
index 2f6311cbe..e4700f86f 100644
--- a/dependencies/includedyaml/emitter.py
+++ b/dependencies/includedyaml/emitter.py
@@ -834,9 +834,9 @@ def analyze_scalar(self, scalar):
         # Spaces followed by breaks, as well as special character are only
         # allowed for double quoted scalars.
         if space_break or special_characters:
-            allow_flow_plain = (
-                allow_block_plain
-            ) = allow_single_quoted = allow_block = False
+            allow_flow_plain = allow_block_plain = allow_single_quoted = allow_block = (
+                False
+            )
 
         # Although the plain scalar writer supports breaks, we never emit
         # multiline plain scalars.
diff --git a/dependencies/tool.py b/dependencies/tool.py
index d8c30c721..599cf9d0f 100644
--- a/dependencies/tool.py
+++ b/dependencies/tool.py
@@ -84,12 +84,14 @@ def from_metadata_yaml(metadata_yaml: str) -> Dict[str, "Tool"]:
                 commit=tool["commit"],
                 build_script=tool.get("build") or "",
                 default_branch=tool.get("default_branch") or None,
-                in_container=tool["in_container"]
-                if tool.get("in_container") is not None
-                else True,
-                in_install=tool["in_install"]
-                if tool.get("in_install") is not None
-                else True,
+                in_container=(
+                    tool["in_container"]
+                    if tool.get("in_container") is not None
+                    else True
+                ),
+                in_install=(
+                    tool["in_install"] if tool.get("in_install") is not None else True
+                ),
                 pdk=tool.get("pdk") or False,
             )
         return final_dict
diff --git a/requirements_lint.txt b/requirements_lint.txt
index ccbde4010..65f5c3882 100644
--- a/requirements_lint.txt
+++ b/requirements_lint.txt
@@ -1,3 +1,3 @@
-black~=22.3.0
+black~=24.3.0
 flake8~=4.0.1
 flake8-no-implicit-concat==0.3.3