Fix incorrect behaviour on early termination - #576
Open
WilliamRoebuck wants to merge 10 commits into
Open
Conversation
WilliamRoebuck
requested review from
FScholPer,
MaciejKaszynski,
anmittag,
antonkri,
pawelrutkaq and
ramceb
as code owners
September 1, 2026 09:41
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 09:41 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 09:41 — with
GitHub Actions
Waiting
WilliamRoebuck
force-pushed
the
fix/issue-553
branch
from
September 1, 2026 09:42
47ffd6c to
4594829
Compare
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 09:42 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 09:42 — with
GitHub Actions
Waiting
Contributor
License Check Results🚀 The license check job ran with the Bazel command: bazel run --lockfile_mode=error //:license-checkStatus: Click to expand output |
WilliamRoebuck
force-pushed
the
fix/issue-553
branch
from
September 1, 2026 09:49
4594829 to
20e63c3
Compare
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 09:49 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 09:49 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 11:38 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 1, 2026 11:38 — with
GitHub Actions
Waiting
WilliamRoebuck
marked this pull request as draft
September 1, 2026 15:48
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 14:14 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 14:14 — with
GitHub Actions
Waiting
WilliamRoebuck
force-pushed
the
fix/issue-553
branch
from
September 3, 2026 14:14
64eca2b to
8079393
Compare
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 14:14 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 14:14 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 15:02 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 15:02 — with
GitHub Actions
Waiting
WilliamRoebuck
marked this pull request as ready for review
September 3, 2026 15:04
| bool terminationIsValid(int32_t exit_code) const; | ||
|
|
||
| /// @brief Returns true if the process is configured to report kRunning | ||
| bool isReporting() const; |
Contributor
There was a problem hiding this comment.
I don't think we should have this as a member as it's a copy the data in the config, should just add
auto& is_reporting = to the methods that use it.
Contributor
Author
There was a problem hiding this comment.
Hmm, I don't think it can be considered a copy because the config doesn't directly provide whether the component is reporting or not. At the moment is_reporting = !config::Native, but that might not always be the case. I prefer the function because otherwise we repeat logic in several places, even if the logic is just !=
| return res; | ||
| } | ||
|
|
||
| bool ProcessInfoNode::terminationIsValid(int32_t exit_code) const |
Contributor
There was a problem hiding this comment.
This is only used in tryHandleTermination should this just be a lambda?
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 15:32 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 15:32 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 15:50 — with
GitHub Actions
Waiting
WilliamRoebuck
requested a deployment
to
workflow-approval
September 3, 2026 15:50 — with
GitHub Actions
Waiting
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
UnexpectedTerminationevent instead of assumingkErrorAfterReadyisValidTermination()andisReporting()common functions forProcessInfoNodeMost likely does not \fix\ #567 but I have not been able to reproduce that failure.
Fix details
The case where the process terminated during activation was not handled correctly. The main fix is at the end of
startProcess(), where we now handle the stored result of the last termination instead of ignoring when a termination happened and hoping thattryHandleTermination()happened at just the right time to report an unexpected termination.