Skip to content

Commit

Permalink
Rename the custom Any union to "AnyValue"
Browse files Browse the repository at this point in the history
  • Loading branch information
Ali-Alnosairi committed Sep 13, 2024
1 parent 200170d commit ff2a0bf
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
import warnings
from os import environ
from time import time_ns
from typing import Callable, Dict, List, Optional, Tuple, Union # noqa
from typing import Any, Callable, Dict, List, Optional, Tuple, Union # noqa

from opentelemetry._logs import Logger as APILogger
from opentelemetry._logs import LoggerProvider as APILoggerProvider
Expand Down Expand Up @@ -69,8 +69,8 @@ class LogDroppedAttributesWarning(UserWarning):

warnings.simplefilter("once", LogDroppedAttributesWarning)

OtelAny = Union[
str, bool, int, float, bytes, List["OtelAny"], Dict[str, "OtelAny"], None
AnyValue = Union[
str, bool, int, float, bytes, List["AnyValue"], Dict[str, "AnyValue"], None
]


Expand Down Expand Up @@ -183,7 +183,7 @@ def __init__(
trace_flags: Optional[TraceFlags] = None,
severity_text: Optional[str] = None,
severity_number: Optional[SeverityNumber] = None,
body: Optional[OtelAny] = None,
body: Optional[AnyValue] = None,
resource: Optional[Resource] = None,
attributes: Optional[Attributes] = None,
limits: Optional[LogLimits] = _UnsetLogLimits,
Expand Down Expand Up @@ -385,8 +385,8 @@ def add_log_record_processor(
def _submit_and_wait(
self,
func: Callable[[LogRecordProcessor], Callable[..., None]],
*args: OtelAny,
**kwargs: OtelAny,
*args: Any,
**kwargs: Any,
):
futures = []
for lp in self._log_record_processors:
Expand Down

0 comments on commit ff2a0bf

Please sign in to comment.