Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package
python-opentelemetry-exporter-otlp-proto-grpc for openSUSE:Factory checked in
at 2025-11-21 16:55:48
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing
/work/SRC/openSUSE:Factory/python-opentelemetry-exporter-otlp-proto-grpc (Old)
and
/work/SRC/openSUSE:Factory/.python-opentelemetry-exporter-otlp-proto-grpc.new.2061
(New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-opentelemetry-exporter-otlp-proto-grpc"
Fri Nov 21 16:55:48 2025 rev:10 rq:1318873 version:1.38.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-opentelemetry-exporter-otlp-proto-grpc/python-opentelemetry-exporter-otlp-proto-grpc.changes
2025-09-23 16:07:32.396218459 +0200
+++
/work/SRC/openSUSE:Factory/.python-opentelemetry-exporter-otlp-proto-grpc.new.2061/python-opentelemetry-exporter-otlp-proto-grpc.changes
2025-11-21 16:56:39.830323604 +0100
@@ -1,0 +2,10 @@
+Mon Nov 17 21:36:43 UTC 2025 - Dirk Müller <[email protected]>
+
+- update to 1.38.0:
+ * Add `rstcheck` to pre-commit to stop introducing invalid RST
+ * logs: extend Logger.emit to accept separated keyword
+ arguments
+ * logs: add warnings for classes that would be deprecated and
+ renamed in 1.39.0
+
+-------------------------------------------------------------------
Old:
----
opentelemetry_exporter_otlp_proto_grpc-1.37.0.tar.gz
New:
----
opentelemetry_exporter_otlp_proto_grpc-1.38.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-opentelemetry-exporter-otlp-proto-grpc.spec ++++++
--- /var/tmp/diff_new_pack.vLqn17/_old 2025-11-21 16:56:40.690359846 +0100
+++ /var/tmp/diff_new_pack.vLqn17/_new 2025-11-21 16:56:40.690359846 +0100
@@ -18,7 +18,7 @@
%{?sle15_python_module_pythons}
Name: python-opentelemetry-exporter-otlp-proto-grpc
-Version: 1.37.0
+Version: 1.38.0
Release: 0
Summary: OpenTelemetry Collector Protobuf over gRPC Exporter
License: Apache-2.0
++++++ opentelemetry_exporter_otlp_proto_grpc-1.37.0.tar.gz ->
opentelemetry_exporter_otlp_proto_grpc-1.38.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/PKG-INFO
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/PKG-INFO
--- old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/PKG-INFO 2020-02-02
01:00:00.000000000 +0100
+++ new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/PKG-INFO 2020-02-02
01:00:00.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 2.4
Name: opentelemetry-exporter-otlp-proto-grpc
-Version: 1.37.0
+Version: 1.38.0
Summary: OpenTelemetry Collector Protobuf over gRPC Exporter
Project-URL: Homepage,
https://github.com/open-telemetry/opentelemetry-python/tree/main/exporter/opentelemetry-exporter-otlp-proto-grpc
Project-URL: Repository, https://github.com/open-telemetry/opentelemetry-python
@@ -23,9 +23,9 @@
Requires-Dist: grpcio<2.0.0,>=1.63.2; python_version < '3.13'
Requires-Dist: grpcio<2.0.0,>=1.66.2; python_version >= '3.13'
Requires-Dist: opentelemetry-api~=1.15
-Requires-Dist: opentelemetry-exporter-otlp-proto-common==1.37.0
-Requires-Dist: opentelemetry-proto==1.37.0
-Requires-Dist: opentelemetry-sdk~=1.37.0
+Requires-Dist: opentelemetry-exporter-otlp-proto-common==1.38.0
+Requires-Dist: opentelemetry-proto==1.38.0
+Requires-Dist: opentelemetry-sdk~=1.38.0
Requires-Dist: typing-extensions>=4.6.0
Description-Content-Type: text/x-rst
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/pyproject.toml
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/pyproject.toml
--- old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/pyproject.toml
2020-02-02 01:00:00.000000000 +0100
+++ new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/pyproject.toml
2020-02-02 01:00:00.000000000 +0100
@@ -30,9 +30,9 @@
"grpcio >= 1.63.2, < 2.0.0; python_version < '3.13'",
"grpcio >= 1.66.2, < 2.0.0; python_version >= '3.13'",
"opentelemetry-api ~= 1.15",
- "opentelemetry-proto == 1.37.0",
- "opentelemetry-sdk ~= 1.37.0",
- "opentelemetry-exporter-otlp-proto-common == 1.37.0",
+ "opentelemetry-proto == 1.38.0",
+ "opentelemetry-sdk ~= 1.38.0",
+ "opentelemetry-exporter-otlp-proto-common == 1.38.0",
"typing-extensions >= 4.6.0",
]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/_log_exporter/__init__.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/_log_exporter/__init__.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/_log_exporter/__init__.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/_log_exporter/__init__.py
2020-02-02 01:00:00.000000000 +0100
@@ -12,7 +12,7 @@
# limitations under the License.
from os import environ
-from typing import Dict, Optional, Sequence, Tuple, Union
+from typing import Dict, Literal, Optional, Sequence, Tuple, Union
from typing import Sequence as TypingSequence
from grpc import ChannelCredentials, Compression
@@ -29,7 +29,6 @@
LogsServiceStub,
)
from opentelemetry.sdk._logs import LogData
-from opentelemetry.sdk._logs import LogRecord as SDKLogRecord
from opentelemetry.sdk._logs.export import LogExporter, LogExportResult
from opentelemetry.sdk.environment_variables import (
_OTEL_PYTHON_EXPORTER_OTLP_GRPC_LOGS_CREDENTIAL_PROVIDER,
@@ -46,11 +45,13 @@
class OTLPLogExporter(
LogExporter,
- OTLPExporterMixin[SDKLogRecord, ExportLogsServiceRequest, LogExportResult],
+ OTLPExporterMixin[
+ Sequence[LogData],
+ ExportLogsServiceRequest,
+ LogExportResult,
+ LogsServiceStub,
+ ],
):
- _result = LogExportResult
- _stub = LogsServiceStub
-
def __init__(
self,
endpoint: Optional[str] = None,
@@ -61,12 +62,11 @@
] = None,
timeout: Optional[float] = None,
compression: Optional[Compression] = None,
- channel_options: Optional[TypingSequence[Tuple[str, str]]] = None,
+ channel_options: Optional[Tuple[Tuple[str, str]]] = None,
):
- if insecure is None:
- insecure = environ.get(OTEL_EXPORTER_OTLP_LOGS_INSECURE)
- if insecure is not None:
- insecure = insecure.lower() == "true"
+ insecure_logs = environ.get(OTEL_EXPORTER_OTLP_LOGS_INSECURE)
+ if insecure is None and insecure_logs is not None:
+ insecure = insecure_logs.lower() == "true"
if (
not insecure
@@ -90,20 +90,18 @@
if compression is None
else compression
)
- endpoint = endpoint or environ.get(OTEL_EXPORTER_OTLP_LOGS_ENDPOINT)
-
- headers = headers or environ.get(OTEL_EXPORTER_OTLP_LOGS_HEADERS)
- super().__init__(
- **{
- "endpoint": endpoint,
- "insecure": insecure,
- "credentials": credentials,
- "headers": headers,
- "timeout": timeout or environ_timeout,
- "compression": compression,
- "channel_options": channel_options,
- }
+ OTLPExporterMixin.__init__(
+ self,
+ endpoint=endpoint or environ.get(OTEL_EXPORTER_OTLP_LOGS_ENDPOINT),
+ insecure=insecure,
+ credentials=credentials,
+ headers=headers or environ.get(OTEL_EXPORTER_OTLP_LOGS_HEADERS),
+ timeout=timeout or environ_timeout,
+ compression=compression,
+ stub=LogsServiceStub,
+ result=LogExportResult,
+ channel_options=channel_options,
)
def _translate_data(
@@ -111,8 +109,11 @@
) -> ExportLogsServiceRequest:
return encode_logs(data)
- def export(self, batch: Sequence[LogData]) -> LogExportResult:
- return self._export(batch)
+ def export( # type: ignore [reportIncompatibleMethodOverride]
+ self,
+ batch: Sequence[LogData],
+ ) -> Literal[LogExportResult.SUCCESS, LogExportResult.FAILURE]:
+ return OTLPExporterMixin._export(self, batch)
def shutdown(self, timeout_millis: float = 30_000, **kwargs) -> None:
OTLPExporterMixin.shutdown(self, timeout_millis=timeout_millis)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
2020-02-02 01:00:00.000000000 +0100
@@ -27,8 +27,11 @@
Dict,
Generic,
List,
+ Literal,
+ NewType,
Optional,
Tuple,
+ Type,
TypeVar,
Union,
)
@@ -53,12 +56,32 @@
from opentelemetry.exporter.otlp.proto.grpc import (
_OTLP_GRPC_CHANNEL_OPTIONS,
)
+from opentelemetry.proto.collector.logs.v1.logs_service_pb2 import (
+ ExportLogsServiceRequest,
+)
+from opentelemetry.proto.collector.logs.v1.logs_service_pb2_grpc import (
+ LogsServiceStub,
+)
+from opentelemetry.proto.collector.metrics.v1.metrics_service_pb2 import (
+ ExportMetricsServiceRequest,
+)
+from opentelemetry.proto.collector.metrics.v1.metrics_service_pb2_grpc import (
+ MetricsServiceStub,
+)
+from opentelemetry.proto.collector.trace.v1.trace_service_pb2 import (
+ ExportTraceServiceRequest,
+)
+from opentelemetry.proto.collector.trace.v1.trace_service_pb2_grpc import (
+ TraceServiceStub,
+)
from opentelemetry.proto.common.v1.common_pb2 import ( # noqa: F401
AnyValue,
ArrayValue,
KeyValue,
)
from opentelemetry.proto.resource.v1.resource_pb2 import Resource # noqa: F401
+from opentelemetry.sdk._logs import LogData
+from opentelemetry.sdk._logs.export import LogExportResult
from opentelemetry.sdk._shared_internal import DuplicateFilter
from opentelemetry.sdk.environment_variables import (
_OTEL_PYTHON_EXPORTER_OTLP_GRPC_CREDENTIAL_PROVIDER,
@@ -71,9 +94,10 @@
OTEL_EXPORTER_OTLP_INSECURE,
OTEL_EXPORTER_OTLP_TIMEOUT,
)
-from opentelemetry.sdk.metrics.export import MetricsData
+from opentelemetry.sdk.metrics.export import MetricExportResult, MetricsData
from opentelemetry.sdk.resources import Resource as SDKResource
from opentelemetry.sdk.trace import ReadableSpan
+from opentelemetry.sdk.trace.export import SpanExportResult
from opentelemetry.util._importlib_metadata import entry_points
from opentelemetry.util.re import parse_env_headers
@@ -92,11 +116,29 @@
logger = getLogger(__name__)
# This prevents logs generated when a log fails to be written to generate
another log which fails to be written etc. etc.
logger.addFilter(DuplicateFilter())
-SDKDataT = TypeVar("SDKDataT")
+SDKDataT = TypeVar(
+ "SDKDataT",
+ TypingSequence[LogData],
+ MetricsData,
+ TypingSequence[ReadableSpan],
+)
ResourceDataT = TypeVar("ResourceDataT")
TypingResourceT = TypeVar("TypingResourceT")
-ExportServiceRequestT = TypeVar("ExportServiceRequestT")
-ExportResultT = TypeVar("ExportResultT")
+ExportServiceRequestT = TypeVar(
+ "ExportServiceRequestT",
+ ExportTraceServiceRequest,
+ ExportMetricsServiceRequest,
+ ExportLogsServiceRequest,
+)
+ExportResultT = TypeVar(
+ "ExportResultT",
+ LogExportResult,
+ MetricExportResult,
+ SpanExportResult,
+)
+ExportStubT = TypeVar(
+ "ExportStubT", TraceServiceStub, MetricsServiceStub, LogsServiceStub
+)
_ENVIRON_TO_COMPRESSION = {
None: None,
@@ -119,7 +161,10 @@
if environ_key in environ
else None
)
- if environ_value not in _ENVIRON_TO_COMPRESSION:
+ if (
+ environ_value not in _ENVIRON_TO_COMPRESSION
+ and environ_value is not None
+ ):
raise InvalidCompressionValueException(environ_key, environ_value)
return _ENVIRON_TO_COMPRESSION[environ_value]
@@ -151,7 +196,7 @@
certificate_file: Optional[str],
client_key_file: Optional[str],
client_certificate_file: Optional[str],
-) -> Optional[ChannelCredentials]:
+) -> ChannelCredentials:
root_certificates = (
_read_file(certificate_file) if certificate_file else None
)
@@ -214,7 +259,7 @@
# pylint: disable=no-member
class OTLPExporterMixin(
- ABC, Generic[SDKDataT, ExportServiceRequestT, ExportResultT]
+ ABC, Generic[SDKDataT, ExportServiceRequestT, ExportResultT, ExportStubT]
):
"""OTLP span exporter
@@ -230,6 +275,8 @@
def __init__(
self,
+ stub: ExportStubT,
+ result: ExportResultT,
endpoint: Optional[str] = None,
insecure: Optional[bool] = None,
credentials: Optional[ChannelCredentials] = None,
@@ -238,10 +285,11 @@
] = None,
timeout: Optional[float] = None,
compression: Optional[Compression] = None,
- channel_options: Optional[TypingSequence[Tuple[str, str]]] = None,
+ channel_options: Optional[Tuple[Tuple[str, str]]] = None,
):
super().__init__()
-
+ self._result = result
+ self._stub = stub
self._endpoint = endpoint or environ.get(
OTEL_EXPORTER_OTLP_ENDPOINT, "http://localhost:4317"
)
@@ -250,15 +298,12 @@
if parsed_url.scheme == "https":
insecure = False
+ insecure_exporter = environ.get(OTEL_EXPORTER_OTLP_INSECURE)
if insecure is None:
- insecure = environ.get(OTEL_EXPORTER_OTLP_INSECURE)
- if insecure is not None:
- insecure = insecure.lower() == "true"
+ if insecure_exporter is not None:
+ insecure = insecure_exporter.lower() == "true"
else:
- if parsed_url.scheme == "http":
- insecure = True
- else:
- insecure = False
+ insecure = parsed_url.scheme == "http"
if parsed_url.netloc:
self._endpoint = parsed_url.netloc
@@ -277,12 +322,12 @@
overridden_options = {
opt_name for (opt_name, _) in channel_options
}
- default_options = [
+ default_options = tuple(
(opt_name, opt_value)
for opt_name, opt_value in _OTLP_GRPC_CHANNEL_OPTIONS
if opt_name not in overridden_options
- ]
- self._channel_options = tuple(default_options) + channel_options
+ )
+ self._channel_options = default_options + channel_options
else:
self._channel_options = tuple(_OTLP_GRPC_CHANNEL_OPTIONS)
@@ -317,24 +362,25 @@
compression=compression,
options=self._channel_options,
)
- self._client = self._stub(self._channel)
+ self._client = self._stub(self._channel) # type: ignore
[reportCallIssue]
self._shutdown_in_progress = threading.Event()
self._shutdown = False
@abstractmethod
def _translate_data(
- self, data: TypingSequence[SDKDataT]
+ self,
+ data: SDKDataT,
) -> ExportServiceRequestT:
pass
def _export(
self,
- data: Union[TypingSequence[ReadableSpan], MetricsData],
+ data: SDKDataT,
) -> ExportResultT:
if self._shutdown:
logger.warning("Exporter already shutdown, ignoring batch")
- return self._result.FAILURE
+ return self._result.FAILURE # type: ignore [reportReturnType]
# FIXME remove this check if the export type for traces
# gets updated to a class that represents the proto
@@ -347,10 +393,10 @@
metadata=self._headers,
timeout=deadline_sec - time(),
)
- return self._result.SUCCESS
+ return self._result.SUCCESS # type: ignore [reportReturnType]
except RpcError as error:
- retry_info_bin = dict(error.trailing_metadata()).get(
- "google.rpc.retryinfo-bin"
+ retry_info_bin = dict(error.trailing_metadata()).get( # type:
ignore [reportAttributeAccessIssue]
+ "google.rpc.retryinfo-bin" # type: ignore
[reportArgumentType]
)
# multiplying by a random number between .8 and 1.2 introduces
a +/20% jitter to each backoff.
backoff_seconds = 2**retry_num * random.uniform(0.8, 1.2)
@@ -362,7 +408,7 @@
+ retry_info.retry_delay.nanos / 1.0e9
)
if (
- error.code() not in _RETRYABLE_ERROR_CODES
+ error.code() not in _RETRYABLE_ERROR_CODES # type: ignore
[reportAttributeAccessIssue]
or retry_num + 1 == _MAX_RETRYS
or backoff_seconds > (deadline_sec - time())
or self._shutdown
@@ -371,13 +417,13 @@
"Failed to export %s to %s, error code: %s",
self._exporting,
self._endpoint,
- error.code(),
- exc_info=error.code() == StatusCode.UNKNOWN,
+ error.code(), # type: ignore
[reportAttributeAccessIssue]
+ exc_info=error.code() == StatusCode.UNKNOWN, # type:
ignore [reportAttributeAccessIssue]
)
- return self._result.FAILURE
+ return self._result.FAILURE # type: ignore
[reportReturnType]
logger.warning(
"Transient error %s encountered while exporting %s to %s,
retrying in %.2fs.",
- error.code(),
+ error.code(), # type: ignore [reportAttributeAccessIssue]
self._exporting,
self._endpoint,
backoff_seconds,
@@ -387,7 +433,7 @@
logger.warning("Shutdown in progress, aborting retry.")
break
# Not possible to reach here but the linter is complaining.
- return self._result.FAILURE
+ return self._result.FAILURE # type: ignore [reportReturnType]
def shutdown(self, timeout_millis: float = 30_000, **kwargs) -> None:
if self._shutdown:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/metric_exporter/__init__.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/metric_exporter/__init__.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/metric_exporter/__init__.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/metric_exporter/__init__.py
2020-02-02 01:00:00.000000000 +0100
@@ -78,7 +78,12 @@
class OTLPMetricExporter(
MetricExporter,
- OTLPExporterMixin[Metric, ExportMetricsServiceRequest, MetricExportResult],
+ OTLPExporterMixin[
+ MetricsData,
+ ExportMetricsServiceRequest,
+ MetricExportResult,
+ MetricsServiceStub,
+ ],
OTLPMetricExporterMixin,
):
"""OTLP metric exporter
@@ -90,9 +95,6 @@
If it is set and the number of data points exceeds the max, the
request will be split.
"""
- _result = MetricExportResult
- _stub = MetricsServiceStub
-
def __init__(
self,
endpoint: str | None = None,
@@ -106,12 +108,11 @@
| None = None,
preferred_aggregation: dict[type, Aggregation] | None = None,
max_export_batch_size: int | None = None,
- channel_options: TypingSequence[Tuple[str, str]] | None = None,
+ channel_options: Tuple[Tuple[str, str]] | None = None,
):
- if insecure is None:
- insecure = environ.get(OTEL_EXPORTER_OTLP_METRICS_INSECURE)
- if insecure is not None:
- insecure = insecure.lower() == "true"
+ insecure_metrics = environ.get(OTEL_EXPORTER_OTLP_METRICS_INSECURE)
+ if insecure is None and insecure_metrics is not None:
+ insecure = insecure_metrics.lower() == "true"
if (
not insecure
@@ -142,6 +143,8 @@
OTLPExporterMixin.__init__(
self,
+ stub=MetricsServiceStub,
+ result=MetricExportResult,
endpoint=endpoint
or environ.get(OTEL_EXPORTER_OTLP_METRICS_ENDPOINT),
insecure=insecure,
@@ -154,7 +157,7 @@
self._max_export_batch_size: int | None = max_export_batch_size
- def _translate_data(
+ def _translate_data( # type: ignore [reportIncompatibleMethodOverride]
self, data: MetricsData
) -> ExportMetricsServiceRequest:
return encode_metrics(data)
@@ -182,6 +185,7 @@
self,
metrics_data: MetricsData,
) -> Iterable[MetricsData]:
+ assert self._max_export_batch_size is not None
batch_size: int = 0
split_resource_metrics: List[ResourceMetrics] = []
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/trace_exporter/__init__.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/trace_exporter/__init__.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/trace_exporter/__init__.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/trace_exporter/__init__.py
2020-02-02 01:00:00.000000000 +0100
@@ -66,7 +66,10 @@
class OTLPSpanExporter(
SpanExporter,
OTLPExporterMixin[
- ReadableSpan, ExportTraceServiceRequest, SpanExportResult
+ Sequence[ReadableSpan],
+ ExportTraceServiceRequest,
+ SpanExportResult,
+ TraceServiceStub,
],
):
# pylint: disable=unsubscriptable-object
@@ -81,9 +84,6 @@
compression: gRPC compression method to use
"""
- _result = SpanExportResult
- _stub = TraceServiceStub
-
def __init__(
self,
endpoint: Optional[str] = None,
@@ -94,12 +94,11 @@
] = None,
timeout: Optional[float] = None,
compression: Optional[Compression] = None,
- channel_options: Optional[TypingSequence[Tuple[str, str]]] = None,
+ channel_options: Optional[Tuple[Tuple[str, str]]] = None,
):
- if insecure is None:
- insecure = environ.get(OTEL_EXPORTER_OTLP_TRACES_INSECURE)
- if insecure is not None:
- insecure = insecure.lower() == "true"
+ insecure_spans = environ.get(OTEL_EXPORTER_OTLP_TRACES_INSECURE)
+ if insecure is None and insecure_spans is not None:
+ insecure = insecure_spans.lower() == "true"
if (
not insecure
@@ -124,18 +123,18 @@
else compression
)
- super().__init__(
- **{
- "endpoint": endpoint
- or environ.get(OTEL_EXPORTER_OTLP_TRACES_ENDPOINT),
- "insecure": insecure,
- "credentials": credentials,
- "headers": headers
- or environ.get(OTEL_EXPORTER_OTLP_TRACES_HEADERS),
- "timeout": timeout or environ_timeout,
- "compression": compression,
- "channel_options": channel_options,
- }
+ OTLPExporterMixin.__init__(
+ self,
+ stub=TraceServiceStub,
+ result=SpanExportResult,
+ endpoint=endpoint
+ or environ.get(OTEL_EXPORTER_OTLP_TRACES_ENDPOINT),
+ insecure=insecure,
+ credentials=credentials,
+ headers=headers or environ.get(OTEL_EXPORTER_OTLP_TRACES_HEADERS),
+ timeout=timeout or environ_timeout,
+ compression=compression,
+ channel_options=channel_options,
)
def _translate_data(
@@ -146,8 +145,8 @@
def export(self, spans: Sequence[ReadableSpan]) -> SpanExportResult:
return self._export(spans)
- def shutdown(self) -> None:
- OTLPExporterMixin.shutdown(self)
+ def shutdown(self, timeout_millis: float = 30_000, **kwargs) -> None:
+ OTLPExporterMixin.shutdown(self, timeout_millis=timeout_millis)
def force_flush(self, timeout_millis: int = 30000) -> bool:
"""Nothing is buffered in this exporter, so this method does
nothing."""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/version/__init__.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/version/__init__.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/src/opentelemetry/exporter/otlp/proto/grpc/version/__init__.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/src/opentelemetry/exporter/otlp/proto/grpc/version/__init__.py
2020-02-02 01:00:00.000000000 +0100
@@ -12,4 +12,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-__version__ = "1.37.0"
+__version__ = "1.38.0"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/tests/test_otlp_exporter_mixin.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/tests/test_otlp_exporter_mixin.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/tests/test_otlp_exporter_mixin.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/tests/test_otlp_exporter_mixin.py
2020-02-02 01:00:00.000000000 +0100
@@ -76,11 +76,14 @@
class OTLPSpanExporterForTesting(
SpanExporter,
OTLPExporterMixin[
- ReadableSpan, ExportTraceServiceRequest, SpanExportResult
+ ReadableSpan,
+ ExportTraceServiceRequest,
+ SpanExportResult,
+ TraceServiceStub,
],
):
- _result = SpanExportResult
- _stub = TraceServiceStub
+ def __init__(self, **kwargs):
+ super().__init__(TraceServiceStub, SpanExportResult, **kwargs)
def _translate_data(
self, data: Sequence[ReadableSpan]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/tests/test_otlp_metrics_exporter.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/tests/test_otlp_metrics_exporter.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/tests/test_otlp_metrics_exporter.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/tests/test_otlp_metrics_exporter.py
2020-02-02 01:00:00.000000000 +0100
@@ -229,13 +229,8 @@
"opentelemetry.exporter.otlp.proto.grpc.exporter.ssl_channel_credentials"
)
@patch("opentelemetry.exporter.otlp.proto.grpc.exporter.secure_channel")
- @patch(
-
"opentelemetry.exporter.otlp.proto.grpc.metric_exporter.OTLPMetricExporter._stub"
- )
# pylint: disable=unused-argument
- def test_no_credentials_error(
- self, mock_ssl_channel, mock_secure, mock_stub
- ):
+ def test_no_credentials_error(self, mock_ssl_channel, mock_secure):
OTLPMetricExporter(insecure=False)
self.assertTrue(mock_ssl_channel.called)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/tests/test_otlp_trace_exporter.py
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/tests/test_otlp_trace_exporter.py
---
old/opentelemetry_exporter_otlp_proto_grpc-1.37.0/tests/test_otlp_trace_exporter.py
2020-02-02 01:00:00.000000000 +0100
+++
new/opentelemetry_exporter_otlp_proto_grpc-1.38.0/tests/test_otlp_trace_exporter.py
2020-02-02 01:00:00.000000000 +0100
@@ -255,13 +255,8 @@
"opentelemetry.exporter.otlp.proto.grpc.exporter.ssl_channel_credentials"
)
@patch("opentelemetry.exporter.otlp.proto.grpc.exporter.secure_channel")
- @patch(
-
"opentelemetry.exporter.otlp.proto.grpc.trace_exporter.OTLPSpanExporter._stub"
- )
# pylint: disable=unused-argument
- def test_no_credentials_error(
- self, mock_ssl_channel, mock_secure, mock_stub
- ):
+ def test_no_credentials_error(self, mock_ssl_channel, mock_secure):
OTLPSpanExporter(insecure=False)
self.assertTrue(mock_ssl_channel.called)