Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jan 29, 2024
1 parent 5732d0b commit 0ee0f11
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 53 deletions.
20 changes: 11 additions & 9 deletions duetector/analyzer/jaeger/analyzer.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,12 @@ def get_find_tracers_request(
service_name=self.generate_service_name(collector_id),
operation_name=self.generate_span_name(tracer_name),
tags=tags,
start_time_min=self._datetime_to_protobuf_timestamp(start_time_min)
if start_time_min
else None,
start_time_max=self._datetime_to_protobuf_timestamp(start_time_max)
if start_time_max
else None,
start_time_min=(
self._datetime_to_protobuf_timestamp(start_time_min) if start_time_min else None
),
start_time_max=(
self._datetime_to_protobuf_timestamp(start_time_max) if start_time_max else None
),
duration_min=Duration(seconds=duration_min) if duration_min else None,
duration_max=Duration(seconds=duration_max) if duration_max else None,
search_depth=search_depth,
Expand Down Expand Up @@ -190,9 +190,11 @@ async def brief(
collector_id=collector_id,
start=self._protobuf_timestamp_to_datetime(start_span.start_time),
end=self._protobuf_timestamp_to_datetime(last_span.start_time),
fields={msg.key: None for msg in start_span.tags}
if not inspect_type
else self.inspect_span(start_span),
fields=(
{msg.key: None for msg in start_span.tags}
if not inspect_type
else self.inspect_span(start_span)
),
count=count,
)

Expand Down
1 change: 1 addition & 0 deletions duetector/analyzer/jaeger/proto/model_pb2.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ class Trace(_message.Message):
process_id: _Optional[str] = ...,
process: _Optional[_Union[Process, _Mapping]] = ...,
) -> None: ...

PROCESS_MAP_FIELD_NUMBER: _ClassVar[int]
SPANS_FIELD_NUMBER: _ClassVar[int]
WARNINGS_FIELD_NUMBER: _ClassVar[int]
Expand Down
88 changes: 44 additions & 44 deletions duetector/analyzer/jaeger/proto/query_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions duetector/analyzer/jaeger/proto/query_pb2.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ class TraceQueryParameters(_message.Message):
key: str
value: str
def __init__(self, key: _Optional[str] = ..., value: _Optional[str] = ...) -> None: ...

DURATION_MAX_FIELD_NUMBER: _ClassVar[int]
DURATION_MIN_FIELD_NUMBER: _ClassVar[int]
OPERATION_NAME_FIELD_NUMBER: _ClassVar[int]
Expand Down

0 comments on commit 0ee0f11

Please sign in to comment.