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

fix: span emit warnings on express instrumentation #1891

Conversation

ReDemoNBR
Copy link
Contributor

Which problem is this PR solving?

Short description of the changes

  • This checks if the span has ended before attemptuing to mutate it by calling span.recordException(...) and span.setStatus(...)

More information can be found in the issue

@ReDemoNBR ReDemoNBR requested a review from a team January 7, 2024 22:45
Copy link

linux-foundation-easycla bot commented Jan 7, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: ReDemoNBR / name: San Mônico (97929c7)
  • ✅ login: JamieDanielson / name: Jamie Danielson (d289b66, 2f427c0)

Signed-off-by: San 'rdn' Mônico <san@monico.com.br>
@ReDemoNBR ReDemoNBR force-pushed the fix/express-instr-span-closed-warnings branch from 77c37d5 to 97929c7 Compare January 7, 2024 23:10
Copy link

codecov bot commented Jan 8, 2024

Codecov Report

Merging #1891 (d289b66) into main (3156c94) will not change coverage.
The diff coverage is 100.00%.

❗ Current head d289b66 differs from pull request most recent head 2f427c0. Consider uploading reports for the commit 2f427c0 to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1891   +/-   ##
=======================================
  Coverage   91.51%   91.51%           
=======================================
  Files         145      145           
  Lines        7427     7427           
  Branches     1486     1486           
=======================================
  Hits         6797     6797           
  Misses        630      630           
Files Coverage Δ
...try-instrumentation-express/src/instrumentation.ts 100.00% <100.00%> (ø)

Copy link
Member

@JamieDanielson JamieDanielson left a comment

Choose a reason for hiding this comment

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

Thanks for this!

@JamieDanielson JamieDanielson merged commit f65f2f1 into open-telemetry:main Jan 18, 2024
15 checks passed
@dyladan dyladan mentioned this pull request Jan 18, 2024
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.

Can not execute the operation on ended Span on express-instrumentation
3 participants