sing
sing copied to clipboard
exceptions: classify QUIC StreamError as canceled
Problem
When running connectivity / latency checks over QUIC/TUIC, the peer may cancel the stream immediately after the check completes. sing-box currently logs this as an ERROR, even though it can be a normal termination pattern for probing traffic (e.g. the remote resets/cancels the stream after responding).
This results in noisy error logs during routine checks.
+0800 2025-12-26 00:00:17 INFO outbound/direct[direct]: outbound connection to cp.cloudflare.com:80
+0800 2025-12-26 00:00:17 ERROR connection: connection upload closed: stream 4 canceled by remote with error code 0
+0800 2025-12-26 00:00:37 ERROR connection: connection upload closed: stream 16 canceled by remote with error code 0
+0800 2025-12-26 00:00:37 ERROR connection: connection upload closed: stream 20 canceled by remote with error code 0
+0800 2025-12-26 00:00:37 ERROR connection: connection upload closed: stream 24 canceled by remote with error code 0