Skip to content

Commit c617908

Browse files
RemiLeheRevathiJambunathan
authored andcommitted
Fix db=None when clicking on points (BLAST-AI-ML#361)
1 parent eacd8bb commit c617908

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

dashboard/app.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,8 @@ def find_simulation(event, db):
239239
print(msg)
240240

241241

242-
def open_simulation_dialog(event, db):
242+
def open_simulation_dialog(event):
243+
db = load_database(state.experiment)
243244
try:
244245
data_directory, file_path = find_simulation(event, db)
245246
state.simulation_video = file_path.endswith(".mp4")
@@ -323,7 +324,7 @@ def home_route():
323324
config={"responsive": True},
324325
click=(
325326
open_simulation_dialog,
326-
"[utils.safe($event), db]",
327+
"[utils.safe($event)]",
327328
),
328329
)
329330
ctrl.figure_update = figure.update

0 commit comments

Comments
 (0)