Skip to content

Commit df13def

Browse files
authored
Merge branch 'main' into main
2 parents 78e3441 + f347716 commit df13def

File tree

2 files changed

+7
-0
lines changed
  • instrumentation/opentelemetry-instrumentation-system-metrics/src/opentelemetry/instrumentation/system_metrics

2 files changed

+7
-0
lines changed

CHANGELOG.md

+2
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3333
([#1980](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1980))
3434
- `opentelemetry-resource-detector-azure` Using new Cloud Resource ID attribute.
3535
([#1976](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1976))
36+
- Do not collect `system.network.connections` by default on macOS which was causing exceptions in metrics collection.
37+
([#2008](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2008))
3638

3739
## Version 1.20.0/0.41b0 (2023-09-01)
3840

instrumentation/opentelemetry-instrumentation-system-metrics/src/opentelemetry/instrumentation/system_metrics/__init__.py

+5
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@
7777

7878
import gc
7979
import os
80+
import sys
8081
import logging
8182
import threading
8283
from platform import python_implementation
@@ -119,6 +120,10 @@
119120
"process.runtime.context_switches": ["involuntary", "voluntary"],
120121
}
121122

123+
if sys.platform == "darwin":
124+
# see https://github.com/giampaolo/psutil/issues/1219
125+
_DEFAULT_CONFIG.pop("system.network.connections")
126+
122127

123128
class SystemMetricsInstrumentor(BaseInstrumentor):
124129
def __init__(

0 commit comments

Comments
 (0)