Spaces:
Running
Running
Fixed critical section
Browse files
server.py
CHANGED
@@ -635,9 +635,9 @@ class LeaderboardServer:
|
|
635 |
)
|
636 |
|
637 |
def get_model_detail(self, submission_id):
|
638 |
-
|
639 |
-
|
640 |
-
|
641 |
-
|
642 |
data = self.submission_id_to_data[submission_id]
|
643 |
-
|
|
|
635 |
)
|
636 |
|
637 |
def get_model_detail(self, submission_id):
|
638 |
+
with self.var_lock.ro:
|
639 |
+
if submission_id not in self.submission_id_to_data:
|
640 |
+
raise gr.Error(f"Submission [{submission_id}] not found")
|
641 |
+
else:
|
642 |
data = self.submission_id_to_data[submission_id]
|
643 |
+
return data["metadata"]
|