[BUG] Failed realm-directory diagnostic replies before cleanup finishes #24

Closed
opened 2026-10-17 12:51:35 +02:00 by erikinkinen · 1 comment
Owner

Summary

With realm-directory diagnostics enabled, a failed preparation can reply before
its original cleanup finishes. A pending cleanup failure must keep the original
request held and prevent a diagnostic reply.

Reproduction

At Launchd 6ea5ba13, run the all-feature test
cleanup_uncertainty_keeps_original_pending_call_and_emits_nothing.
CI 414 reports an extra reply: seven messages where the control expects six.

Expected and actual behavior

A failed admitted diagnostic request should wait until its original realm is
retired. Absence of an immediate result alone does not establish that state;
the original source can still have a pending retirement operation.
The ordinary reply format, successful diagnostic path and caller checks should
retain their existing behavior.

Environment and identity

  • Launchd 6ea5ba13, LibIPC 9116efed; Linux x86-64, Rust 1.93.1 in CI.
  • Feature: launchd-integration-realm-directory-diagnostic.
  • The operation uses the caller's existing Launchd endpoint and original source.

Evidence and prior checks

CI 414 preserves the
original failure. The fix
waits for full retirement, strengthens the cleanup-failure control and covers a
provider that remains busy before retirement. Formatting, strict Clippy,
681 default tests, 687 opt-in tests and all 23 Markdown files pass locally.

Tracking

Related: diagnostic operation
and implementation.

  • Keep failed admitted diagnostics pending until original retirement.
  • Cover cleanup failure, provider progress and successful retirement.
  • Confirm the new controls in current CI.
## Summary With realm-directory diagnostics enabled, a failed preparation can reply before its original cleanup finishes. A pending cleanup failure must keep the original request held and prevent a diagnostic reply. ## Reproduction At Launchd `6ea5ba13`, run the all-feature test `cleanup_uncertainty_keeps_original_pending_call_and_emits_nothing`. CI 414 reports an extra reply: seven messages where the control expects six. ## Expected and actual behavior A failed admitted diagnostic request should wait until its original realm is retired. Absence of an immediate result alone does not establish that state; the original source can still have a pending retirement operation. The ordinary reply format, successful diagnostic path and caller checks should retain their existing behavior. ## Environment and identity - Launchd `6ea5ba13`, LibIPC `9116efed`; Linux x86-64, Rust 1.93.1 in CI. - Feature: `launchd-integration-realm-directory-diagnostic`. - The operation uses the caller's existing Launchd endpoint and original source. ## Evidence and prior checks [CI 414](https://git.erikinkinen.fi/erix/launchd/actions/runs/414) preserves the original failure. [The fix](https://git.erikinkinen.fi/erix/launchd/commit/3e69090ee433a66f10290dea764c219f0f4c3613) waits for full retirement, strengthens the cleanup-failure control and covers a provider that remains busy before retirement. Formatting, strict Clippy, 681 default tests, 687 opt-in tests and all 23 Markdown files pass locally. ## Tracking Related: [diagnostic operation](https://git.erikinkinen.fi/erix/launchd/issues/22) and [implementation](https://git.erikinkinen.fi/erix/launchd/pulls/2). - [x] Keep failed admitted diagnostics pending until original retirement. - [x] Cover cleanup failure, provider progress and successful retirement. - [x] Confirm the new controls in current CI.
Author
Owner

CI 416 passes at 3e69090ee4: the new retirement controls pass in the 687-test suite, with formatting, strict Clippy, Rustdoc, both freestanding checks and all 23 Markdown files clean. This closes the diagnostic retirement regression. The original guest run remains tracked in #22.

CI 416 passes at 3e69090ee433a66f10290dea764c219f0f4c3613: the new retirement controls pass in the 687-test suite, with formatting, strict Clippy, Rustdoc, both freestanding checks and all 23 Markdown files clean. This closes the diagnostic retirement regression. The original guest run remains tracked in #22.
erikinkinen added this to the Alpha 1 milestone 2026-10-30 09:34:33 +01:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
erix/launchd#24
No description provided.