Browse Source

Direct warning when data rate is not set in GUI

master
Benito Marcote 1 month ago
parent
commit
78953052ad
1 changed files with 6 additions and 0 deletions
  1. +6
    -0
      app.py

+ 6
- 0
app.py View File

@@ -1142,6 +1142,12 @@ def compute_observation(n_clicks, band, starttime, starthour, duration, source,
dash.no_update, dash.no_update, dash.no_update, dash.no_update, dash.no_update, \
dash.no_update, dash.no_update, dash.no_update, dash.no_update

if datarate <= 0:
temp = [alert_message(["You need to select the data rate for the observation. "]), dash.no_update]
return *[temp if out_center else temp[::-1]][0], dash.no_update, dash.no_update, dash.no_update, \
dash.no_update, dash.no_update, dash.no_update, dash.no_update, dash.no_update, \
dash.no_update, dash.no_update, dash.no_update, dash.no_update

try:
target_source = observation.Source(convert_colon_coord(source), 'Source')
except ValueError as e:


Loading…
Cancel
Save