opentelemetry-js icon indicating copy to clipboard operation
opentelemetry-js copied to clipboard

refactor(otlp-exporter-base): use `getStringFromEnv` instead of `process.env`

Open weyert opened this issue 7 months ago • 1 comments

Which problem is this PR solving?

Updates the code to user the helper utilities to retrieve environment variable values

Fixes #5561

Short description of the changes

Used the getStringFromEnv-helper function instead of process.env

Type of change

Please delete options that are not relevant.

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

How Has This Been Tested?

I have ran the relevant unit tests to verify the tests still pass as expected.

Checklist:

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

weyert avatar Apr 06 '25 14:04 weyert

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 95.06%. Comparing base (31640eb) to head (321a1be). :warning: Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5594   +/-   ##
=======================================
  Coverage   95.06%   95.06%           
=======================================
  Files         307      307           
  Lines        8025     8025           
  Branches     1623     1623           
=======================================
  Hits         7629     7629           
  Misses        396      396           
Files with missing lines Coverage Δ
...e/src/configuration/otlp-http-env-configuration.ts 95.83% <100.00%> (ø)
:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Apr 06 '25 14:04 codecov[bot]

@weyert do you have time to address the changes proposed? I would be happy to merge this PR once done and the conflict is resolved.

david-luna avatar Jun 25 '25 21:06 david-luna

Please fix comments and conflicts and we can merge this :)

dyladan avatar Jul 16 '25 16:07 dyladan