Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

Log stream errors on a single line - #291

Merged
cwasicki merged 1 commit into
frequenz-floss:v0.x.xfrom
cwasicki:msg
Nov 30, 2026
Merged

cwasicki merged 1 commit into
frequenz-floss:v0.x.xfrom
cwasicki:msg

Conversation

@cwasicki

@cwasicki cwasicki commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

The string form of AioRpcError spans several lines, which splits each retry warning into multiple journal entries. Log each field with !r instead, so line breaks are escaped, and skip the debug string when it only repeats the code and details.

@github-actions github-actions Bot added part:docs Affects the documentation part:tests Affects the unit, integration and performance (benchmarks) tests part:code Affects the code in general labels Nov 13, 2026
Marenz
Marenz previously approved these changes Nov 13, 2026
Comment thread src/frequenz/client/base/streaming.py Resolved
The string form of `AioRpcError` spans several lines, which splits each
retry warning into multiple journal entries. Log each field with `!r`
instead, so line breaks are escaped, and skip the debug string when it
only repeats the code and details.

Signed-off-by: cwasicki <126617870+cwasicki@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The log formatter and its tests differ from the documented status-and-optional-details format, so the implementation or PR description needs to be aligned.

1 open issue
What changed in this PR

This PR makes GrpcStreamBroadcaster error logs single-line so retry warnings are not split across journal entries.

Changes:

  • Adds compact error formatting with escaped line breaks and omits redundant debug strings.
  • Tests formatting edge cases and updates expected retry and failure logs.
  • Documents the logging change in the release notes.
File Description
tests/​streaming/​test_grpc_stream_broadcaster.py Adds formatter tests and updates expected log messages.
src/​frequenz/​client/​base/​streaming.py Adds single-line gRPC error formatting for stream logs.
RELEASE_NOTES.md Records the single-line logging fix.

Review effort: Balanced

Comment thread src/frequenz/client/base/streaming.py Resolved
@cwasicki
cwasicki requested a review from llucax November 27, 2026 14:27
@llucax llucax added this to the v0.11.5 milestone Nov 27, 2026
@cwasicki
cwasicki added this pull request to the merge queue Nov 30, 2026
Merged via the queue into frequenz-floss:v0.x.x with commit 797e40e Nov 30, 2026
9 checks passed
@cwasicki
cwasicki deleted the msg branch November 30, 2026 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

part:code Affects the code in general part:docs Affects the documentation part:tests Affects the unit, integration and performance (benchmarks) tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants