Commit Graph
2 Commits
Author SHA1 Message Date
Eric Traut b6087365cd Repair app-server daemon packages with update --from-cli (#65046)
## Why

A daemon with a dangling package selection or a missing executable can
fail to start, and leftover logs can make an absent installation look
like an existing one.

## What changed

- Let `codex app-server daemon update --from-cli` install or repair and
  pin the daemon from a complete CLI package. Point missing-executable
  errors to that command. Repair checks that the daemon and updater are
  stopped and that the package selection has stayed unchanged.
- Let `codex app-server daemon start` bootstrap a missing installation
  even when old daemon logs remain. Use legacy logs to infer a stopped
  standalone installation only when its package selection still exists
  and dedicated daemon logs are absent.
- Allow repair to replace a dangling Windows junction whose target is
  directly under the daemon's releases directory.

## Testing

Extend coverage for startup with leftover logs, package repair after
losing the selection or executable, repair blocked by a starting
daemon or updater, and replacement of a dangling Windows junction.

GitOrigin-RevId: 679266cc22b7ff7a34bbd41c2bf0659d3068eb75
2026-12-01 17:56:54 +00:00
Eric Traut 97771b1d78 Isolate daemon package tests to reduce disk contention (#53897)
## Why

Daemon package tests copy full debug CLI packages. Running these I/O-heavy cases alongside other tests can increase shared-disk writeback pressure.

## What changed

- Move package installation and replacement coverage into the `app_server_daemon_package` test binary, sharing daemon fixtures with the lifecycle tests.
- Reserve all nextest test threads for each package test and add an exclusive Bazel target that runs the cases serially on Linux and macOS.
- Hard-link the prepared fixture executable during package setup, while retaining real independent package copies in the installer.

GitOrigin-RevId: 255ac8caf75d9eb61bafe68f1f9bcfa99ee72484
2026-10-14 07:13:22 +00:00