Skip to content

Conversation

@overbalance
Copy link
Contributor

Which problem is this PR solving?

Static analysis tools in browser/Edge Runtime environments warn about accessing process.argv0 directly. This change accesses the property dynamically to avoid those warnings.

Short description of the changes

  • Access process.argv0 via dynamic property lookup (process[ARGV0]) to avoid static analysis warnings
  • Lazy-evaluate and cache the service name on first call

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

  • Existing unit tests pass
  • Verified no static analysis warnings in Edge Runtime environments

Checklist:

  • Followed the style guidelines of this project
  • Unit tests have been added
  • Documentation has been updated

@overbalance overbalance requested a review from a team as a code owner December 29, 2025 18:34
@overbalance overbalance added the browser Browser-specific additions or benefits label Dec 29, 2025
@codecov
Copy link

codecov bot commented Dec 29, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.41%. Comparing base (f9a5c36) to head (40954a6).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6257      +/-   ##
==========================================
+ Coverage   95.40%   95.41%   +0.01%     
==========================================
  Files         316      316              
  Lines        9570     9574       +4     
  Branches     2214     2214              
==========================================
+ Hits         9130     9135       +5     
+ Misses        440      439       -1     
Files with missing lines Coverage Δ
...pentelemetry-resources/src/default-service-name.ts 100.00% <100.00%> (+14.28%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@overbalance overbalance force-pushed the overbalance/convert-to-runtime branch 2 times, most recently from 2ee3e75 to b665d09 Compare December 29, 2025 19:18
@overbalance overbalance force-pushed the overbalance/convert-to-runtime branch from ec46c10 to 9a1d2ff Compare December 29, 2025 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

browser Browser-specific additions or benefits

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant