Skip to content

Control and monitoring script should fail if given invalid board name

When giving an invalid board name at start the control and monitoring script doesn't fail so it's possible to miss such a misconfiguration.

Furthermore it doesn't return an error if an invalid board (and register) is passed in via the HTTP interface.

Example:

$ python3.6 l1scout_monitoring_and_control.py -j address_table/address_table_kcu1500_64shift_rw.json -d 1 -b kcu1500                                         
Traceback (most recent call last):
  File "l1scout_monitoring_and_control.py", line 170, in <module>
    device = str(config_json[board]["driver"])
KeyError: 'kcu1500'
 * Serving Flask app "WebApp.flask_app" (lazy loading)
 * Environment: production
   WARNING: This is a development server. Do not use it in a production deployment.
   Use a production WSGI server instead.
 * Debug mode: off
 * Running on http://127.0.0.1:8080/ (Press CTRL+C to quit)


Write request on:
kcu1500_demux scoutDemux_zs_threhold_eg_0p5GeV 100
Edited by Dinyar Rabady