njcuk9999 / apero-drs

A PipelinE to Reduce Observations - The DRS for SPIRou (CFHT)
MIT License
12 stars 0 forks source link

[APERO] Gracefully exit after W[10-503-00007] #728

Closed njcuk9999 closed 5 months ago

njcuk9999 commented 11 months ago

If apero_processing was running and you got the message; W[10-503-00007]: No files after whitelisting. Skipping. And you typed "N". This message is expected and can be ignored (You should however probably report that there are no files for this run (either due to the night used in the manual_trigger or the settings in the run.ini file. If you get this message and did not have this prompt please report.

This should give a nicer error than the current error:

Traceback (most recent call last):
  File "/cosmos99/nirps/git-bin/apero-drs-online/apero/core/utils/drs_startup.py", line 433, in run
    llmain = func(recipe, params)
  File "/cosmos99/nirps/git-bin/apero-drs-online/apero/tools/recipes/bin/apero_processing.py", line 230, in __main__
    raise e
  File "/cosmos99/nirps/git-bin/apero-drs-online/apero/tools/recipes/bin/apero_processing.py", line 166, in __main__
    rlist = drs_processing.generate_run_list(params, findexdbm, runtable,
  File "/cosmos99/nirps/git-bin/apero-drs-online/apero/tools/module/processing/drs_processing.py", line 887, in generate_run_list
    ref_condition, req_obs_dirs = gen_global_condition(params, findexdbm,
  File "/cosmos99/nirps/git-bin/apero-drs-online/apero/tools/module/processing/drs_processing.py", line 2229, in gen_global_condition
    sys.exit()
SystemExit

This should be possible