Handle non-UTF-8 pod logs in must-gather log comparison#5471
Conversation
Pod logs can contain non-UTF-8 binary data (e.g. when nginx logs a raw TLS ClientHello sent to a plaintext HTTP port). The Kubernetes Python client's pod.log() fails with UnicodeDecodeError on such data. Skip the log comparison for pods with non-decodable logs since the content cannot be retrieved as text for comparison. assisted by: claude code claude-opus-4-6 Signed-off-by: Ohad <orevah@redhat.com>
|
/build-and-push-container |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe ChangesMust-gather log decode error handling
Estimated code review effort: 1 (Trivial) | ~3 minutes Related issues: None specified Related PRs: None specified Suggested labels: bug-fix, tests Suggested reviewers: None specified Poem: A rabbit hopped through logs one night, / Found bytes that wouldn't decode right, / Instead of crashing, panicked, torn, / It logged a warning, carried on. / No more UTF-8 fright! 🐇📜 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Warning Review ran into problems🔥 ProblemsLinked repositories: Your configuration references 1 linked repositories, but your current plan allows 0. Analyzed ``, skipped Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Report bugs in Issues Welcome! 🎉This pull request will be automatically processed with the following features: 🔄 Automatic Actions
📋 Available CommandsPR Status Management
Review & Approval
Testing & Validation
Container Operations
Cherry-pick Operations
Branch Management
Custom Commands
Label Management
✅ Merge RequirementsThis PR will be automatically approved when the following conditions are met:
📊 Review ProcessApprovers and ReviewersApprovers:
Reviewers:
Available Labels
AI Features
Security Checks
💡 Tips
For more information, please refer to the project documentation or contact the maintainers. |
|
New container for quay.io/openshift-cnv/openshift-virtualization-tests:pr-5471 published |
What this PR does / why we need it:
Pod logs can contain non-UTF-8 binary data (e.g. when nginx logs a raw TLS ClientHello sent to a plaintext HTTP port). The Kubernetes Python client's pod.log() fails with UnicodeDecodeError on such data.
Skip the log comparison for pods with non-decodable logs since the content cannot be retrieved as text for comparison.
assisted by: claude code claude-opus-4-6
Which issue(s) this PR fixes:
Failures in test_kubevirt_logs_collected in dual stream lane for iuo-ocs and rhcos10 iuo-ocs
Special notes for reviewer:
jira-ticket:
https://redhat.atlassian.net/browse/CNV-91551
https://redhat.atlassian.net/browse/CNV-91552
Summary by CodeRabbit