Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(api): restore empty error blocks on cancelled runs (#15215)
I think this would be a subtle side effect of a previous pr trying to improve PE end behavior. The reason this fix is required is that when a client cancels a protocol by stopping the engine, the `StopAction` sets the run result (good) and doesn't set a run error (good, correct, there wasn't one, this is a cancel). In 7.2, with the behavior this PR now restores, a `FinishAction` that might contain an error wouldn't set that error in the run if it already had a _result_, whether or not it had an _error_. In 7.3, it would set the error if the engine had no error, which it wouldn't, because there is no error when you stop. ## Testing - [x] With this PR, cancelling a run on a real robot causes the ODD to show an inactive error details button - [x] With this PR, stopping a run by hitting an estop still causes the ODD and desktop to display that an estop error cancelled the run Closes RQA-2737 --------- Co-authored-by: Max Marrone <[email protected]>
- Loading branch information