diff --git a/src/common/gen/save_config.py b/src/common/gen/save_config.py index c12e8dd26..018a1fc75 100644 --- a/src/common/gen/save_config.py +++ b/src/common/gen/save_config.py @@ -381,7 +381,9 @@ if __name__ == "__main__": if apis: for api in apis: endpoint_data = api.endpoint.replace("http://", "").split(":") - err = db.add_instance(endpoint_data[0], endpoint_data[1].replace("/", ""), api.host) + err = db.add_instance( + endpoint_data[0], endpoint_data[1].replace("/", ""), api.host + ) if err: logger.warning(err) diff --git a/src/common/utils/jobs.py b/src/common/utils/jobs.py index 5fa98724d..8234a355b 100644 --- a/src/common/utils/jobs.py +++ b/src/common/utils/jobs.py @@ -70,9 +70,12 @@ def is_cached_file( return is_cached and cached_file -def get_file_in_db(file: Union[str, Path], db, *, job_name: Optional[str] = None) -> Optional[bytes]: +def get_file_in_db( + file: Union[str, Path], db, *, job_name: Optional[str] = None +) -> Optional[bytes]: cached_file = db.get_job_cache_file( - job_name or basename(getsourcefile(_getframe(1))).replace(".py", ""), normpath(file) + job_name or basename(getsourcefile(_getframe(1))).replace(".py", ""), + normpath(file), ) if not cached_file: return None