Skip to content

Add OpenTelemetry Proguard rules for compile-only annotations#2080

Merged
0xnm merged 1 commit into
developfrom
nogorodnikov/add-otel-proguard-rules-for-compile-only-annotations
Jun 12, 2024
Merged

Add OpenTelemetry Proguard rules for compile-only annotations#2080
0xnm merged 1 commit into
developfrom
nogorodnikov/add-otel-proguard-rules-for-compile-only-annotations

Conversation

@0xnm

@0xnm 0xnm commented Jun 12, 2024

Copy link
Copy Markdown
Member

What does this PR do?

There is the following Proguard error when trying to minify OpenTelemetry module:

ERROR: R8: Missing class com.google.auto.value.AutoValue (referenced from: io.opentelemetry.api.common.AttributeKeyImpl and 2 other contexts)
Missing class com.google.errorprone.annotations.MustBeClosed (referenced from: io.opentelemetry.context.Scope io.opentelemetry.context.Context.makeCurrent() and 3 other contexts)

In fact both these annotations are not needed in runtime, so it is safely to ignore them.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Make sure you discussed the feature or bugfix with the maintaining team in an Issue
  • Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)

@0xnm
0xnm requested review from a team as code owners June 12, 2024 14:19
Comment thread features/dd-sdk-android-trace-otel/consumer-rules.pro

@mariusc83 mariusc83 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM but I think we should remove the ones in the sample app and wear apps to make sure these rules are tested.

@0xnm
0xnm force-pushed the nogorodnikov/add-otel-proguard-rules-for-compile-only-annotations branch from 58c09e3 to 88ff084 Compare June 12, 2024 14:39
@0xnm
0xnm requested a review from mariusc83 June 12, 2024 14:39
@codecov-commenter

codecov-commenter commented Jun 12, 2024

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.56%. Comparing base (5197289) to head (88ff084).

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2080      +/-   ##
===========================================
- Coverage    68.73%   68.56%   -0.17%     
===========================================
  Files          719      719              
  Lines        26571    26567       -4     
  Branches      4472     4472              
===========================================
- Hits         18262    18214      -48     
- Misses        7123     7138      +15     
- Partials      1186     1215      +29     

see 28 files with indirect coverage changes

@0xnm
0xnm merged commit 308f26e into develop Jun 12, 2024
@0xnm
0xnm deleted the nogorodnikov/add-otel-proguard-rules-for-compile-only-annotations branch June 12, 2024 15:26
@xgouchet xgouchet added this to the 2.11.x milestone Jul 31, 2024
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.

4 participants