Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ dependencies = [
"py-machineid",
"protobuf==6.31.1",
"dijkstar==2.6.0",
"lattica==1.0.7",
"lattica==1.0.8",
]

[project.scripts]
Expand Down
4 changes: 3 additions & 1 deletion src/parallax/p2p/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ def run(self):
node_info = self.get_node_info()
if node_info == {}:
logger.error("Failed to get node info, try again after 10 seconds")
del self.lattica
self.lattica.close()
self.lattica = None
time.sleep(10)
return self.run()
Expand Down Expand Up @@ -642,6 +642,8 @@ def shutdown(self):
self.announcer.join()
if self.routing_table_updater is not None:
self.routing_table_updater.join()
if self.lattica is not None:
self.lattica.close()


def launch_p2p_server(
Expand Down
1 change: 1 addition & 0 deletions src/parallax/server/node_chat_http_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ def build_lattica(self):
logger.warning("Scheduler peer id not found, waiting for 1 second.")
time.sleep(1)

self.lattica.close()
return False

def chat_completion(self, request_data, request_id: str, received_ts: int):
Expand Down