Skip to content

Implement application-level command response timeouts #166

Description

@dfederm

Per spec (§8.2.5), during interviews and runtime communication, the controller MUST timeout waiting for Report responses using a ReportTime timer (CommandTime + 1s for interviews, CommandTime + 10s for polling). Currently only serial-level ACK timeouts exist (1600ms in ZWaveSerialPortCoordinator).

Scope:

  • Add a configurable ReportTime timeout to CommandClass.AwaitNextReportAsync() (currently waits indefinitely via TaskCompletionSource)
  • Default timeout: CommandTime + 1s for interviews, CommandTime + 10s for polling scenarios
  • When timeout expires: cancel the awaiting TCS, log the timeout, allow the interview to continue with next CC
  • Update the interview flow in Node.InterviewCommandClassesAsync() to handle timeout exceptions gracefully - mark the CC as partially interviewed rather than failing the entire interview
  • Extend Missing Error/Timeout Handling for Callbacks #121's callback timeout handling to also cover these application-level timeouts

Design notes: This is distinct from serial-level timeouts (which handle frame delivery) and callback timeouts (#121, which handle REQ→callback flow). This is about the application-level wait for a CC Report in response to a CC Get. The timeout should be measured from successful transmission (ACK received) to Report received.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions