Skip to content

bug: circuit-breaker integration test still counts the old operator-queue call for the dormant alert (stale since #3246) #3343

Open

Description

@webmixgamer

Summary

tests/integration/test_circuit_breaker.py::TestDormantState::test_dormant_transition_emits_operator_queue_alert fails on dev. #3246 part 1 (#3255) moved the circuit breaker's dormant alarm onto the platform-alerts seam (services/platform_alerts.py), so services/agent_client/circuit.py now files it through db.create_platform_operator_queue_item. The test still counts the old call:

assert fake_db.create_operator_queue_item.call_count == 1
AssertionError: assert 0 == 1

The alert itself still fires. The captured log shows the circuit_breaker_dormant entry created through create_platform_operator_queue_item. Only the test is out of date.

Context

Acceptance Criteria

  • The test asserts the platform-alert path: one create_platform_operator_queue_item call (or the platform-alerts subject for the dormant kind) on the closed/open → dormant transition.
  • It still proves the alert fires exactly once, and not again on a later failure while the circuit stays dormant.
  • The test passes against a running integration Redis (/verify-local integration stage, or pytest tests/integration/test_circuit_breaker.py).

Technical Notes

Metadata

Metadata

Assignees

No one assigned

    Labels

    complexity-lowComplexity: low (board points 1-3)priority-p3Nice-to-havestatus-readyGreenlit and ready for development (vetted; counterpart to status-incubating)theme-reliabilityTheme: Reliabilitytype-bugBug fix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions