Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the correct format when deserializing body field from logs #2178

Merged
merged 2 commits into from
Oct 12, 2024

Conversation

RazvanRotari
Copy link
Contributor

@RazvanRotari RazvanRotari commented Oct 6, 2024

Fixes #2173

Changes

Use the correct format when serializing/deserializing body field from logs. Item inside arrays will not be wrapped inside a 'value' field.

Merge requirement checklist

  • CONTRIBUTING guidelines followed
  • Unit tests added/updated (if applicable)
  • Appropriate CHANGELOG.md files updated for non-trivial, user-facing changes
  • Changes in public API reviewed (if applicable)

Copy link

codecov bot commented Oct 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 79.2%. Comparing base (e524bdb) to head (533d66b).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##            main   #2178     +/-   ##
=======================================
- Coverage   79.2%   79.2%   -0.1%     
=======================================
  Files        121     121             
  Lines      20870   20870             
=======================================
- Hits       16534   16532      -2     
- Misses      4336    4338      +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@lalitb lalitb left a comment

Choose a reason for hiding this comment

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

Thanks @RazvanRotari. Nicely done.

@lalitb
Copy link
Member

lalitb commented Oct 10, 2024

@RazvanRotari Can you fix the lint error, so this can be merged ?

error: for loop over a single element
   --> opentelemetry-proto/tests/grpc_build.rs:116:5
    |
116 | /     for path in ["common.v1.AnyValue.value"] {
117 | |         builder = builder
118 | |         .field_attribute(path, "#[cfg_attr(feature =\"with-serde\", serde(flatten, serialize_with = \"crate::proto::serializers::serializ...
119 | |     }
    | |_____^

@RazvanRotari
Copy link
Contributor Author

@lalitb Fixed the lint.

@cijothomas cijothomas merged commit 20fd454 into open-telemetry:main Oct 12, 2024
25 checks passed
@RazvanRotari RazvanRotari deleted the correct_array branch October 14, 2024 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Arrays in AnyValue are serialized diffently from opentelemetry-js
3 participants