diff --git a/netx_api/ume_alarm_ws_log.py b/netx_api/ume_alarm_ws_log.py index 2506573..1538a9f 100644 --- a/netx_api/ume_alarm_ws_log.py +++ b/netx_api/ume_alarm_ws_log.py @@ -24,8 +24,11 @@ _SUBSCRIPTION_MISSING_MARKERS: tuple[str, ...] = ( "status-reason: subscription not found", "non-101 status: 503", "non-101 status: 404", + "non-101 status: 500", "handshake status 404", "handshake status 503", + # ZTE UME often returns HTML 500 when the stream id is gone/invalid. + "handshake status 500", ) diff --git a/tests/test_ume_sync.py b/tests/test_ume_sync.py index c048405..b5283e6 100644 --- a/tests/test_ume_sync.py +++ b/tests/test_ume_sync.py @@ -753,6 +753,11 @@ class UmeAlarmNotificationTests(unittest.TestCase): 'ume_request_failed:DELETE ... 400:{"errorInfo":"subscription not exist!"}' ) ) + self.assertTrue( + is_ume_subscription_missing_error( + "Handshake status 500 Server Error -+-+- {'content-type': 'text/html'}" + ) + ) def test_cancel_returns_needs_cleanup_when_ume_missing(self): from time import time as _time