Skip to content

Commit

Permalink
fix(sdk-metrics): Add missing catch and handle error in promise of `P…
Browse files Browse the repository at this point in the history
…eriodicExportingMetricReader` (#5006)
  • Loading branch information
jj22ee authored Sep 24, 2024
1 parent 4574bf5 commit 5627d84
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ For semantic convention package changes, see the [semconv CHANGELOG](packages/se
### :bug: (Bug Fix)

* fix(sdk-trace-base): avoid keeping non-string `status.message` on `Span#setStatus()` [#4999](https://github.com/open-telemetry/opentelemetry-js/pull/4999) @pichlermarc
* fix(sdk-metrics): Add missing catch and handle error in promise of `PeriodicExportingMetricReader` [#5006](https://github.com/open-telemetry/opentelemetry-js/pull/5006) @jj22ee

### :books: (Refine Doc)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,8 @@ export class PeriodicExportingMetricReader extends MetricReader {
.waitForAsyncAttributes?.()
.then(doExport, err =>
diag.debug('Error while resolving async portion of resource: ', err)
);
)
.catch(globalErrorHandler);
} else {
await doExport();
}
Expand Down

0 comments on commit 5627d84

Please sign in to comment.