Author silvan
Recipients jendrik, malte, silvan
Date 2017-10-19.13:44:43
Jendrik and I discussed this a bit further:

If we wanted to use exit codes consistently in the driver, then we should no
longer return "0" as a synonym to "search found a plan", and treat all other
results like "unsolvable", "out of time" etc (independently of the component) as
"errors" in the sense that a non-zero exit code is returned. In the current
implementation of the test module of the driver, we always expect exit code 0
when using pyhton's subprocess module, independently of which component is being
called. This makes testing of exit codes inconsistent, treating some as
exceptions and others not. (For example, also a call to ./
without any arguments returns 0.) 

Changing the driver to always return a unique non-zero exit code depending on
the result of the translator and the search would make this more consistent. The
drawback of this approach would be that the driver basically never returns with
zero, hence making it more difficult to be used in other scripts, since
"non-zero" usually means "error". I personally would still prefer this solution
over the current situation, where exit codes of the search components are just
passed through the driver (and translator exit codes are not at all considered).

An alternative is to not use exit codes for the driver at all, but to write or
print the results of the components (which should still continue use different
exit codes) to some file or stdout. 

What do you think of these solutions, Malte?
Date User Action Args
2017-10-19 13:44:43silvansetmessageid: <>
2017-10-19 13:44:43silvansetrecipients: + silvan, malte, jendrik
2017-10-19 13:44:43silvanlinkissue739 messages
2017-10-19 13:44:43silvancreate