exasim-project / OBR

A runner for OpenFOAM benchmarks
BSD 3-Clause "New" or "Revised" License
3 stars 1 forks source link

remove `obr find` references #125

Open lupeterm opened 1 year ago

lupeterm commented 1 year ago

For instance:

[core.py:67]     ERROR: SubprocessError:/pfs/data5/home/kit/istm/kh2521/OBR/src/obr/core/core.pyobr.core.coreCommand '['blockMesh']' returned non-zero exit status 1. check: 'obr find --state failure' for more info

Probably just replace this with the equivalent call to obr query

greole commented 1 year ago

Good thing to remove obr find references, however, the idea of obr find extended obr query. Currently, obr query allows to query key value pairs in job docs and so to find the log file of the failed process (the exact query might be difficult though). Obr find was meant to display the content of said log file.

lupeterm commented 1 year ago

Maybe I could change the exception to be more specific, for example

'['blockMesh']' returned non-zero exit status 1 for job with id XY. check: 'obr query -q "{key:'job_id', value:'XY} --log blockMesh" for more info

Thus, i would also add a --log or --get-log <operation> flag that would additionally print the most recent log file of the specified operation.

greole commented 1 year ago

That is a great idea, but I guess --log needs a pager function like git log to handle large log files. Also, we would need to clarify how to handle many exceptions.

lupeterm commented 1 year ago

As a starting point, we could like into modules like pager.