Skip to content

fix: Undefined stns in blob Trace #1039

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

Merged
merged 1 commit into from
May 16, 2024
Merged

fix: Undefined stns in blob Trace #1039

merged 1 commit into from
May 16, 2024

Conversation

cwli24
Copy link
Contributor

@cwli24 cwli24 commented May 16, 2024

Fix an instance of undefined error in Session Trace feature introduced in v1.259.0. Harvest will now no longer be attempted if there are no trace nodes to send.

Overview

Fix a scenario wherein stns is undefined and causing problem when .length property is accessed for it. Instead, prepareHarvest will early exit when such is the case.

Related Issue(s)

https://new-relic.atlassian.net/browse/NR-270488

Testing

Component test added

Copy link

Asset Size Report

Merging this pull request will result in the following asset size changes:

Agent Asset Previous Size New Size Diff
lite loader 31.44 kB / 11.03 kB (gzip) 31.44 kB / 11.03 kB (gzip) 0% / 0% (gzip)
lite async-chunk 50.96 kB / 16.56 kB (gzip) 50.96 kB / 16.56 kB (gzip) 0% / 0% (gzip)
pro loader 52.7 kB / 17.87 kB (gzip) 52.7 kB / 17.86 kB (gzip) 0% / -0.01% (gzip)
pro async-chunk 93.43 kB / 28.2 kB (gzip) 93.45 kB / 28.21 kB (gzip) 0.02% / 0.02% (gzip)
spa loader 60.81 kB / 20.37 kB (gzip) 60.81 kB / 20.37 kB (gzip) 0% / 0.01% (gzip)
spa async-chunk 108.7 kB / 32.63 kB (gzip) 108.72 kB / 32.63 kB (gzip) 0.02% / 0.02% (gzip)
lite-polyfills loader 125.44 kB / 40.32 kB (gzip) 125.44 kB / 40.32 kB (gzip) 0% / 0% (gzip)
lite-polyfills async-chunk 65.7 kB / 18.9 kB (gzip) 65.7 kB / 18.9 kB (gzip) 0% / 0% (gzip)
pro-polyfills loader 147.15 kB / 46.58 kB (gzip) 147.15 kB / 46.58 kB (gzip) 0% / 0% (gzip)
pro-polyfills async-chunk 113.94 kB / 30.14 kB (gzip) 113.96 kB / 30.15 kB (gzip) 0.01% / 0.03% (gzip)
spa-polyfills loader 155.35 kB / 48.75 kB (gzip) 155.35 kB / 48.75 kB (gzip) 0% / 0.01% (gzip)
spa-polyfills async-chunk 130.94 kB / 34.77 kB (gzip) 130.96 kB / 34.78 kB (gzip) 0.01% / 0.03% (gzip)

Copy link

codecov bot commented May 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.38%. Comparing base (a37e9f5) to head (520362e).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1039      +/-   ##
==========================================
+ Coverage   87.02%   87.38%   +0.35%     
==========================================
  Files         156      156              
  Lines        7098     7100       +2     
  Branches     1393     1394       +1     
==========================================
+ Hits         6177     6204      +27     
+ Misses        797      779      -18     
+ Partials      124      117       -7     
Flag Coverage Δ
integration-tests 91.24% <ø> (+0.18%) ⬆️
unit-tests 75.97% <100.00%> (+0.65%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

Copy link
Member

@metal-messiah metal-messiah left a comment

Choose a reason for hiding this comment

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

Approved pending test suite run

Copy link

github-actions bot commented May 16, 2024

Static Badge

Last ran on May 16, 2024 11:28:27 CDT
Checking merge of (520362e) into main (a37e9f5)

@cwli24 cwli24 merged commit 1a87991 into main May 16, 2024
52 of 53 checks passed
@cwli24 cwli24 deleted the fix-stns-undefined branch May 16, 2024 17:23
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.

2 participants