swri-robotics / bag-database

A server that catalogs bag files and provides a web-based UI for accessing them.
Other
345 stars 71 forks source link

Use exit code to determine script success #136

Closed pjreed closed 3 years ago

pjreed commented 3 years ago

This adds the ability to determine script success based on the exit code returned by the script. It adds a new column to the ScriptResults database table, ExitCode, and will populated it based on the results of the script. If the script's stdout contains a JSON object with the key useExitCodeForSuccess that is set to true, instead of using the presence of stderr to determine whether a script was successful, it will consider an exit code of 0 to be success and anything else to be failure.

Fixes #133