Skip to content

fix: loosen gRPC DNS error message assertion in test_client_error#89

Merged
mfiedorowicz merged 1 commit intodevelopfrom
obs-2681-fix-flaky-test_client_error-assertion-for-grpc-dns-error
Apr 16, 2026
Merged

fix: loosen gRPC DNS error message assertion in test_client_error#89
mfiedorowicz merged 1 commit intodevelopfrom
obs-2681-fix-flaky-test_client_error-assertion-for-grpc-dns-error

Conversation

@mfiedorowicz
Copy link
Copy Markdown
Member

@mfiedorowicz mfiedorowicz commented Apr 16, 2026

Summary

  • Loosens the test_client_error assertion to check for "invalid:8081" in gRPC error details instead of a specific DNS error message format
  • The gRPC DNS error message format changed across versions, causing the test to fail despite the underlying behavior being correct

Test plan

  • Run pytest tests/test_client.py::test_client_error and verify it passes
  • Confirm the assertion still validates that the error references the expected host

Resolves OBS-2681

The assertion checked for a specific gRPC DNS error message format that
changed across gRPC versions. Check for the hostname instead, which is
present in all message variants.

Resolves OBS-2681
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 16, 2026

Coverage

Coverage Report
FileStmtsMissCoverMissing
/opt/hostedtoolcache/Python/3.11.15/x64/lib/python3.11/site-packages/netboxlabs/diode/sdk
   chunking.py33197%112
   client.py5094092%165–166, 185–187, 190–193, 482, 548, 553, 557, 643–648, 693–695, 700, 705, 710, 715, 725, 729, 733, 755, 776, 778, 852, 883, 891, 933, 969, 984–985, 992–993
   exceptions.py44393%69, 82–83
TOTAL6014493% 

Tests Skipped Failures Errors Time
185 0 💤 0 ❌ 0 🔥 2.376s ⏱️

@mfiedorowicz mfiedorowicz self-assigned this Apr 16, 2026
@mfiedorowicz mfiedorowicz merged commit e4c5af3 into develop Apr 16, 2026
6 checks passed
@mfiedorowicz mfiedorowicz deleted the obs-2681-fix-flaky-test_client_error-assertion-for-grpc-dns-error branch April 16, 2026 10:05
@github-actions
Copy link
Copy Markdown

🎉 This PR is included in version 1.11.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants