Skip to content

TUI power inhibitor ignores prevent_sleep_while_streaming=false #452

Description

@pigmej

Summary

[power].prevent_sleep_while_streaming = false disables the shared daemon power inhibitor, but the TUI client can still acquire a power inhibitor while a turn is processing.

On Linux this can still hit the systemd-inhibit / polkit / pkttyagent path even though the config says sleep prevention is disabled.

Repro

  1. Set:

    [power]
    prevent_sleep_while_streaming = false
  2. Start a Linux TUI/remote-client session.

  3. Run an agent turn.

  4. Observe the power-inhibit path can still be used from the TUI sleep guard.

Expected

When prevent_sleep_while_streaming = false, neither the daemon nor the TUI should acquire a power inhibitor.

Reference fix

I could not create a PR from this account, but pushed a minimal reference fix here:

The main change gates sync_sleep_guard() on config().power.prevent_sleep_while_streaming, matching the existing daemon-side config gate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    autonomous: clearHands-off: unambiguous bug, obvious fix, no decisions. Don't even look - an agent can fully solve.bugSomething isn't workingpriority: mediumP2 - normal prioritytriage: fixed-pending-releaseFixed in code/committed; will close automatically on next release

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions