-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make error codes consistent with e.g qpOASES #4
Comments
I agree, that it would be easier for quite adding of the solver, but in general it is quite dangerous if return codes are not checked and converted to the caller's native syntax in the calling interface. Once you do these checks you will have to do it differently for each solver anyways, I fear. Regarding From an outside point of view |
I always check for return codes. My main objection was that "OK" like return codes could be the same: 0.
This is still an "OK" situation, no? Solver returning simple "OK" can mean "hey, I found an optimal solution"? 😄 Hitting time or iteration constraint are exceptions and I agree they should return something else than pure "OK". |
I also strongly suggest to have a simple set of return values for "naive" users. qpOASES uses the following ones:
which is all a typical user needs to know. Btw, the C++ core of qpOASES also throws more sophisticated error messages, but the user can easily convert them to the ones mentioned above by calling "getSimpleStatus". I found that I good compromise. |
👍 |
It would be much easier to switch between the solvers if the error codes are similar. At least for "OK"-like return codes. In particular, is there really a need that
QPDUNES_OK
andQPDUNES_SUCC_OPTIMAL_SOLUTION_FOUND
have different values? Moreover, @jfrasch, is there really a need for the later one??The text was updated successfully, but these errors were encountered: