Skip to content

OTLP exporter uses bound_instruments #1236

@ocelotl

Description

@ocelotl

The OTLP exporter attempts to use bound_instruments. This causes an attribute error:

Exception in thread Thread-1:
Traceback (most recent call last):
  File "/home/ocelotl/.pyenv/versions/3.8.3/lib/python3.8/threading.py", line 932, in _bootstrap_inner
    self.run()
  File "/home/ocelotl/codeboten/opentelemetry-python/opentelemetry-sdk/src/opentelemetry/sdk/metrics/export/controller.py", line 48, in run
    self.tick()
  File "/home/ocelotl/codeboten/opentelemetry-python/opentelemetry-sdk/src/opentelemetry/sdk/metrics/export/controller.py", line 60, in tick
    self.exporter.export(self.meter.processor.checkpoint_set())
  File "/home/ocelotl/codeboten/opentelemetry-python/exporter/opentelemetry-exporter-otlp/src/opentelemetry/exporter/otlp/metrics_exporter/__init__.py", line 248, in export
    return self._export(metrics)
  File "/home/ocelotl/codeboten/opentelemetry-python/exporter/opentelemetry-exporter-otlp/src/opentelemetry/exporter/otlp/exporter.py", line 166, in _export
    request=self._translate_data(data),
  File "/home/ocelotl/codeboten/opentelemetry-python/exporter/opentelemetry-exporter-otlp/src/opentelemetry/exporter/otlp/metrics_exporter/__init__.py", line 201, in _translate_data
    data_points=_get_data_points(sdk_metric, data_point_class),
  File "/home/ocelotl/codeboten/opentelemetry-python/exporter/opentelemetry-exporter-otlp/src/opentelemetry/exporter/otlp/metrics_exporter/__init__.py", line 71, in _get_data_points
    ) in sdk_metric.instrument.bound_instruments.items():
AttributeError: 'SumObserver' object has no attribute 'bound_instruments'

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions