diff --git a/gunicorn_config.py b/gunicorn_config.py index 7239acd9..8500dad6 100644 --- a/gunicorn_config.py +++ b/gunicorn_config.py @@ -61,9 +61,7 @@ def on_starting(server): except ImportError: print("psutil not installed, skipping memory usage reporting") - print("=" * 80) print("Gunicorn initialization complete, forking workers...") - print("=" * 80) def on_exit(server): diff --git a/lightrag/kg/networkx_impl.py b/lightrag/kg/networkx_impl.py index c42a1981..d42db33a 100644 --- a/lightrag/kg/networkx_impl.py +++ b/lightrag/kg/networkx_impl.py @@ -92,8 +92,6 @@ class NetworkXStorage(BaseGraphStorage): logger.info( f"Loaded graph from {self._graphml_xml_file} with {preloaded_graph.number_of_nodes()} nodes, {preloaded_graph.number_of_edges()} edges" ) - else: - logger.info("Created new empty graph") else: preloaded_graph = NetworkXStorage.load_nx_graph(self._graphml_xml_file) self._graph = preloaded_graph or nx.Graph() @@ -101,8 +99,8 @@ class NetworkXStorage(BaseGraphStorage): logger.info( f"Loaded graph from {self._graphml_xml_file} with {preloaded_graph.number_of_nodes()} nodes, {preloaded_graph.number_of_edges()} edges" ) - else: - logger.info("Created new empty graph") + + logger.info("Created new empty graph") self._node_embed_algorithms = { "node2vec": self._node2vec_embed, diff --git a/lightrag/kg/shared_storage.py b/lightrag/kg/shared_storage.py index d8cf71c9..c57771ba 100644 --- a/lightrag/kg/shared_storage.py +++ b/lightrag/kg/shared_storage.py @@ -107,9 +107,9 @@ def try_initialize_namespace(namespace: str) -> bool: if namespace not in _init_flags: _init_flags[namespace] = True - direct_log(f"Process {os.getpid()} ready to initialize namespace {namespace}") + direct_log(f"Process {os.getpid()} ready to initialize storage namespace: [{namespace}]") return True - direct_log(f"Process {os.getpid()} namespace {namespace} already to initialized") + direct_log(f"Process {os.getpid()} storage namespace already to initialized: [{namespace}]") return False @@ -146,7 +146,7 @@ def get_namespace_object(namespace: str) -> Any: else: _share_objects[namespace] = None direct_log( - f"Created namespace({namespace}): type={type(_share_objects[namespace])}, pid={os.getpid()}" + f"Created namespace: {namespace}(type={type(_share_objects[namespace])})" ) return _share_objects[namespace] @@ -169,7 +169,7 @@ def get_namespace_data(namespace: str) -> Dict[str, Any]: else: _shared_dicts[namespace] = {} direct_log( - f"Created namespace({namespace}): type={type(_shared_dicts[namespace])}, pid={os.getpid()}" + f"Created namespace: {{namespace}}({type(_shared_dicts[namespace])}) " ) return _shared_dicts[namespace]