diff --git a/scripts/check_base_registry.py b/scripts/check_base_registry.py
index 1db533a..663c6e0 100755
--- a/scripts/check_base_registry.py
+++ b/scripts/check_base_registry.py
@@ -4,10 +4,9 @@
 import json
 import re
 
-
 parser = argparse.ArgumentParser()
-parser.add_argument('-b', '--base', default=None, required=True)
-parser.add_argument('-f', '--file', default=None, required=True)
+parser.add_argument("-b", "--base", default=None, required=True)
+parser.add_argument("-f", "--file", default=None, required=True)
 args = parser.parse_args()
 
 with open(args.file) as error_file:
@@ -15,9 +14,14 @@
 
     with open(args.base) as base_file:
         base_json = json.load(base_file)
-        for message_name, message_data in base_json['Messages'].items():
-            message_id = base_json['RegistryPrefix'] + '.' + \
-                base_json['RegistryVersion'] + '.' + message_name
+        for message_name, message_data in base_json["Messages"].items():
+            message_id = (
+                base_json["RegistryPrefix"]
+                + "."
+                + base_json["RegistryVersion"]
+                + "."
+                + message_name
+            )
             message_found = False
             index = 0
             for i, error in enumerate(error_data):
@@ -29,33 +33,38 @@
                 print("{} not found".format(message_id))
                 continue
 
-            error_info = error_data[index:index + 15]
+            error_info = error_data[index : index + 15]
             error_str = " ".join(error_info)
             error_str = re.sub(
-                'std::to_string\\(arg(\\d+)\\)',
-                'arg\\1',
-                error_str)
-            error_str = re.sub('"\n\\s*"', '', error_str, re.MULTILINE)
+                "std::to_string\\(arg(\\d+)\\)", "arg\\1", error_str
+            )
+            error_str = re.sub('"\n\\s*"', "", error_str, re.MULTILINE)
             error_str = re.sub(
                 '"\\s*\\+\\s*arg(\\d+)\\s*\\+\n?\\s*"',
-                '%\\1',
+                "%\\1",
                 error_str,
-                re.MULTILINE)
-            if message_data['Message'] not in error_str:
+                re.MULTILINE,
+            )
+            if message_data["Message"] not in error_str:
                 print(
                     "{}: error in Message: {}".format(
-                        message_id,
-                        message_data['Message']))
+                        message_id, message_data["Message"]
+                    )
+                )
                 print(error_str)
 
-            if message_data['MessageSeverity'] not in error_str:
-                print("{}: error in MessageSeverity: {}".format(
-                    message_id, message_data['MessageSeverity']))
+            if message_data["MessageSeverity"] not in error_str:
+                print(
+                    "{}: error in MessageSeverity: {}".format(
+                        message_id, message_data["MessageSeverity"]
+                    )
+                )
                 print(error_str)
 
-            if message_data['Resolution'] not in error_str:
+            if message_data["Resolution"] not in error_str:
                 print(
                     "{}: error in Resolution: {}".format(
-                        message_id,
-                        message_data['Resolution']))
+                        message_id, message_data["Resolution"]
+                    )
+                )
                 print(error_str)
diff --git a/scripts/parse_registries.py b/scripts/parse_registries.py
index bfe87ef..369bebf 100755
--- a/scripts/parse_registries.py
+++ b/scripts/parse_registries.py
@@ -1,14 +1,14 @@
 #!/usr/bin/env python3
+import argparse
 import json
 import os
 
 import requests
-import argparse
 
-PRAGMA_ONCE = '''#pragma once
-'''
+PRAGMA_ONCE = """#pragma once
+"""
 
-WARNING = '''/****************************************************************
+WARNING = """/****************************************************************
  *                 READ THIS WARNING FIRST
  * This is an auto-generated header which contains definitions
  * for Redfish DMTF defined messages.
@@ -17,9 +17,12 @@
  * this file are owned by DMTF.  Any modifications to these files
  * should be first pushed to the relevant registry in the DMTF
  * github organization.
- ***************************************************************/'''
+ ***************************************************************/"""
 
-REGISTRY_HEADER = PRAGMA_ONCE + WARNING + '''
+REGISTRY_HEADER = (
+    PRAGMA_ONCE
+    + WARNING
+    + """
 #include "registries.hpp"
 
 #include <array>
@@ -28,25 +31,20 @@
 
 namespace redfish::registries::{}
 {{
-'''
+"""
+)
 
 SCRIPT_DIR = os.path.dirname(os.path.realpath(__file__))
 
 include_path = os.path.realpath(
-    os.path.join(
-        SCRIPT_DIR,
-        "..",
-        "redfish-core",
-        "include",
-        "registries"))
+    os.path.join(SCRIPT_DIR, "..", "redfish-core", "include", "registries")
+)
 
-proxies = {
-    'https': os.environ.get("https_proxy", None)
-}
+proxies = {"https": os.environ.get("https_proxy", None)}
 
 
 def make_getter(dmtf_name, header_name, type_name):
-    url = 'https://redfish.dmtf.org/registries/{}'.format(dmtf_name)
+    url = "https://redfish.dmtf.org/registries/{}".format(dmtf_name)
     dmtf = requests.get(url, proxies=proxies)
     dmtf.raise_for_status()
     json_file = json.loads(dmtf.text)
@@ -62,72 +60,68 @@
         except BaseException:
             print("{} not found".format(file))
 
-        with open(file, 'w') as registry:
+        with open(file, "w") as registry:
             registry.write(REGISTRY_HEADER.format(namespace))
             # Parse the Registry header info
             registry.write(
                 "const Header header = {{\n"
-                "    \"{json_dict[@Redfish.Copyright]}\",\n"
-                "    \"{json_dict[@odata.type]}\",\n"
-                "    \"{json_dict[Id]}\",\n"
-                "    \"{json_dict[Name]}\",\n"
-                "    \"{json_dict[Language]}\",\n"
-                "    \"{json_dict[Description]}\",\n"
-                "    \"{json_dict[RegistryPrefix]}\",\n"
-                "    \"{json_dict[RegistryVersion]}\",\n"
-                "    \"{json_dict[OwningEntity]}\",\n"
+                '    "{json_dict[@Redfish.Copyright]}",\n'
+                '    "{json_dict[@odata.type]}",\n'
+                '    "{json_dict[Id]}",\n'
+                '    "{json_dict[Name]}",\n'
+                '    "{json_dict[Language]}",\n'
+                '    "{json_dict[Description]}",\n'
+                '    "{json_dict[RegistryPrefix]}",\n'
+                '    "{json_dict[RegistryVersion]}",\n'
+                '    "{json_dict[OwningEntity]}",\n'
                 "}};\n"
                 "constexpr const char* url =\n"
-                "    \"{url}\";\n"
+                '    "{url}";\n'
                 "\n"
                 "constexpr std::array registry =\n"
                 "{{\n".format(
                     json_dict=json_dict,
                     url=url,
-                ))
+                )
+            )
 
             messages_sorted = sorted(json_dict["Messages"].items())
             for messageId, message in messages_sorted:
                 registry.write(
                     "    MessageEntry{{\n"
-                    "        \"{messageId}\",\n"
+                    '        "{messageId}",\n'
                     "        {{\n"
-                    "            \"{message[Description]}\",\n"
-                    "            \"{message[Message]}\",\n"
-                    "            \"{message[MessageSeverity]}\",\n"
+                    '            "{message[Description]}",\n'
+                    '            "{message[Message]}",\n'
+                    '            "{message[MessageSeverity]}",\n'
                     "            {message[NumberOfArgs]},\n"
                     "            {{".format(
-                        messageId=messageId,
-                        message=message
-                    ))
+                        messageId=messageId, message=message
+                    )
+                )
                 paramTypes = message.get("ParamTypes")
                 if paramTypes:
                     for paramType in paramTypes:
                         registry.write(
-                            "\n"
-                            "                \"{}\",".format(paramType)
+                            '\n                "{}",'.format(paramType)
                         )
                     registry.write("\n            },\n")
                 else:
                     registry.write("},\n")
                 registry.write(
-                    "            \"{message[Resolution]}\",\n"
-                    "        }}}},\n".format(message=message))
+                    '            "{message[Resolution]}",\n'
+                    "        }}}},\n".format(message=message)
+                )
 
-            registry.write(
-                "\n};\n"
-                "\n"
-                "enum class Index\n"
-                "{\n"
-            )
+            registry.write("\n};\n\nenum class Index\n{\n")
             for index, (messageId, message) in enumerate(messages_sorted):
                 messageId = messageId[0].lower() + messageId[1:]
-                registry.write(
-                    "    {} = {},\n".format(messageId, index))
+                registry.write("    {} = {},\n".format(messageId, index))
             registry.write(
-                "}};\n"
-                "}} // namespace redfish::registries::{}\n"
-                .format(namespace))
+                "}};\n}} // namespace redfish::registries::{}\n".format(
+                    namespace
+                )
+            )
 
 
 def get_privilege_string_from_list(privilege_list):
@@ -138,9 +132,9 @@
         for privilege in privileges:
             if privilege == "NoAuth":
                 continue
-            privilege_string += "\""
+            privilege_string += '"'
             privilege_string += privilege
-            privilege_string += "\",\n"
+            privilege_string += '",\n'
         if privilege != "NoAuth":
             privilege_string = privilege_string[:-2]
         privilege_string += "}"
@@ -158,7 +152,10 @@
     return "Or".join(names)
 
 
-PRIVILEGE_HEADER = PRAGMA_ONCE + WARNING + '''
+PRIVILEGE_HEADER = (
+    PRAGMA_ONCE
+    + WARNING
+    + """
 #include "privileges.hpp"
 
 #include <array>
@@ -167,29 +164,34 @@
 
 namespace redfish::privileges
 {
-'''
+"""
+)
 
 
 def make_privilege_registry():
-    path, json_file, type_name, url = \
-        make_getter('Redfish_1.3.0_PrivilegeRegistry.json',
-                    'privilege_registry.hpp', 'privilege')
-    with open(path, 'w') as registry:
+    path, json_file, type_name, url = make_getter(
+        "Redfish_1.3.0_PrivilegeRegistry.json",
+        "privilege_registry.hpp",
+        "privilege",
+    )
+    with open(path, "w") as registry:
         registry.write(PRIVILEGE_HEADER)
 
         privilege_dict = {}
         for mapping in json_file["Mappings"]:
             # first pass, identify all the unique privilege sets
             for operation, privilege_list in mapping["OperationMap"].items():
-                privilege_dict[get_privilege_string_from_list(
-                    privilege_list)] = (privilege_list, )
+                privilege_dict[
+                    get_privilege_string_from_list(privilege_list)
+                ] = (privilege_list,)
         for index, key in enumerate(privilege_dict):
-            (privilege_list, ) = privilege_dict[key]
+            (privilege_list,) = privilege_dict[key]
             name = get_variable_name_for_privilege_set(privilege_list)
             registry.write(
                 "const std::array<Privileges, {length}> "
-                "privilegeSet{name} = {key};\n"
-                .format(length=len(privilege_list), name=name, key=key)
+                "privilegeSet{name} = {key};\n".format(
+                    length=len(privilege_list), name=name, key=key
+                )
             )
             privilege_dict[key] = (privilege_list, name)
 
@@ -198,26 +200,29 @@
             registry.write("// {}\n".format(entity))
             for operation, privilege_list in mapping["OperationMap"].items():
                 privilege_string = get_privilege_string_from_list(
-                    privilege_list)
+                    privilege_list
+                )
                 operation = operation.lower()
 
                 registry.write(
                     "const static auto& {}{} = privilegeSet{};\n".format(
-                        operation,
-                        entity,
-                        privilege_dict[privilege_string][1]))
+                        operation, entity, privilege_dict[privilege_string][1]
+                    )
+                )
             registry.write("\n")
         registry.write(
-            "} // namespace redfish::privileges\n"
-            "// clang-format on\n")
+            "} // namespace redfish::privileges\n// clang-format on\n"
+        )
 
 
 def main():
     parser = argparse.ArgumentParser()
     parser.add_argument(
-        '--registries', type=str,
+        "--registries",
+        type=str,
         default="base,task_event,resource_event,privilege",
-        help="Comma delimited list of registries to update")
+        help="Comma delimited list of registries to update",
+    )
 
     args = parser.parse_args()
 
@@ -225,17 +230,27 @@
     files = []
 
     if "base" in registries:
-        files.append(make_getter('Base.1.13.0.json',
-                                 'base_message_registry.hpp',
-                                 'base'))
+        files.append(
+            make_getter(
+                "Base.1.13.0.json", "base_message_registry.hpp", "base"
+            )
+        )
     if "task_event" in registries:
-        files.append(make_getter('TaskEvent.1.0.3.json',
-                                 'task_event_message_registry.hpp',
-                                 'task_event'))
+        files.append(
+            make_getter(
+                "TaskEvent.1.0.3.json",
+                "task_event_message_registry.hpp",
+                "task_event",
+            )
+        )
     if "resource_event" in registries:
-        files.append(make_getter('ResourceEvent.1.0.3.json',
-                                 'resource_event_message_registry.hpp',
-                                 'resource_event'))
+        files.append(
+            make_getter(
+                "ResourceEvent.1.0.3.json",
+                "resource_event_message_registry.hpp",
+                "resource_event",
+            )
+        )
 
     update_registries(files)
 
diff --git a/scripts/update_schemas.py b/scripts/update_schemas.py
index da9c346..459d045 100755
--- a/scripts/update_schemas.py
+++ b/scripts/update_schemas.py
@@ -1,14 +1,13 @@
 #!/usr/bin/env python3
-import requests
-import zipfile
-from io import BytesIO
-from packaging.version import parse
-
 import os
-from collections import OrderedDict, defaultdict
 import shutil
-
 import xml.etree.ElementTree as ET
+import zipfile
+from collections import OrderedDict, defaultdict
+from io import BytesIO
+
+import requests
+from packaging.version import parse
 
 VERSION = "DSP8010_2022.2"
 
@@ -42,7 +41,7 @@
     "ComputerSystemCollection",
     "Drive",
     "DriveCollection",
-    'EnvironmentMetrics',
+    "EnvironmentMetrics",
     "EthernetInterface",
     "EthernetInterfaceCollection",
     "Event",
@@ -254,7 +253,6 @@
 
 csdl_filenames.sort(key=version_sort_key)
 with open(metadata_index_path, "w") as metadata_index:
-
     metadata_index.write('<?xml version="1.0" encoding="UTF-8"?>\n')
     metadata_index.write(
         "<edmx:Edmx xmlns:edmx="
@@ -270,7 +268,6 @@
             continue
 
         with open(os.path.join(schema_path, filename), "wb") as schema_out:
-
             metadata_index.write(
                 '    <edmx:Reference Uri="/redfish/v1/schema/'
                 + filename
@@ -289,16 +286,14 @@
                             namespace = data_child.attrib["Namespace"]
                             if namespace.startswith("RedfishExtensions"):
                                 metadata_index.write(
-                                    "        "
-                                    '<edmx:Include Namespace="'
+                                    '        <edmx:Include Namespace="'
                                     + namespace
                                     + '"  Alias="Redfish"/>\n'
                                 )
 
                             else:
                                 metadata_index.write(
-                                    "        "
-                                    '<edmx:Include Namespace="'
+                                    '        <edmx:Include Namespace="'
                                     + namespace
                                     + '"/>\n'
                                 )
@@ -392,6 +387,6 @@
     for schema_file in json_schema_files:
         hpp_file.write('        "{}",\n'.format(schema_file))
 
-    hpp_file.write("    };\n" "}\n")
+    hpp_file.write("    };\n}\n")
 
 zip_ref.close()
diff --git a/scripts/websocket_test.py b/scripts/websocket_test.py
index 85b2c0d..21c7f16 100755
--- a/scripts/websocket_test.py
+++ b/scripts/websocket_test.py
@@ -3,20 +3,23 @@
 # Example of streaming sensor values from openbmc using the /subscribe api
 # requires websockets package to be installed
 
+import argparse
 import asyncio
-import ssl
-import websockets
 import base64
 import json
-import argparse
+import ssl
+
+import websockets
 
 parser = argparse.ArgumentParser()
 parser.add_argument("--host", help="Host to connect to", required=True)
 parser.add_argument(
-    "--username", help="Username to connect with", default="root")
+    "--username", help="Username to connect with", default="root"
+)
 parser.add_argument("--password", help="Password to use", default="0penBmc")
-parser.add_argument('--ssl', default=True,
-                    action=argparse.BooleanOptionalAction)
+parser.add_argument(
+    "--ssl", default=True, action=argparse.BooleanOptionalAction
+)
 
 args = parser.parse_args()
 
@@ -29,27 +32,30 @@
     "altitude": "Meters",
     "current": "Amps",
     "energy": "Joules",
-    "cfm": "CFM"
+    "cfm": "CFM",
 }
 
 
 async def hello():
-    protocol = 'ws'
+    protocol = "ws"
     if args.ssl:
-        protocol += 's'
-    uri = '{}://{}/subscribe'.format(protocol, args.host)
+        protocol += "s"
+    uri = "{}://{}/subscribe".format(protocol, args.host)
     ssl_context = ssl.SSLContext()
-    authbytes = "{}:{}".format(args.username, args.password).encode('ascii')
-    auth = "Basic {}".format(base64.b64encode(authbytes).decode('ascii'))
+    authbytes = "{}:{}".format(args.username, args.password).encode("ascii")
+    auth = "Basic {}".format(base64.b64encode(authbytes).decode("ascii"))
     headers = {"Authorization": auth}
-    async with \
-        websockets.connect(uri, ssl=ssl_context, extra_headers=headers) \
-            if args.ssl else websockets.connect(uri, extra_headers=headers) \
-            as websocket:
-        request = json.dumps({
-            "paths": ["/xyz/openbmc_project/sensors"],
-            "interfaces": ["xyz.openbmc_project.Sensor.Value"]
-        })
+    async with websockets.connect(
+        uri, ssl=ssl_context, extra_headers=headers
+    ) if args.ssl else websockets.connect(
+        uri, extra_headers=headers
+    ) as websocket:
+        request = json.dumps(
+            {
+                "paths": ["/xyz/openbmc_project/sensors"],
+                "interfaces": ["xyz.openbmc_project.Sensor.Value"],
+            }
+        )
         await websocket.send(request)
 
         while True:
