Skip to content

Set exit status based on success/failure? #12

@rpgoldman

Description

@rpgoldman

For integrating pandaPIengine into pipelines, scripts, etc. it would be helpful if it was easy to tell whether it had succeeded in finding a plan or not.

For this, it would help if the exit status was set to 2 (or some other designated value) on search failure. Looking at the code, it seems like an exit status of 1 is reserved for an error condition.

I have had a start at trying to make a MR for this. It seems to be straightforward for translation mode, and mostly straightforward for the heuristic search mode, but for the SAT planner option, I can't figure out all of the ways that solve_with_sat_planner and its subsidiary function solve_with_sat_planner_linear_bound_increase can exit (the while(true) loop in the latter I can't figure out -- how does it exit on failure here?)

Any suggestions?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions