Skip to content

Commit 9ecd908

Browse files
committed
linting
1 parent 809c978 commit 9ecd908

File tree

3 files changed

+18
-16
lines changed

3 files changed

+18
-16
lines changed

ingestion/v1alpha/events_get.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,20 +41,20 @@ def get_event(http_session: requests.AuthorizedSession, proj_id: str,
4141
proj_instance: str, proj_region: str, event_id: str) -> None:
4242
"""Get event details from Chronicle using the Events Get API.
4343
44-
Args:
45-
http_session: Authorized session for HTTP requests.
46-
proj_id: GCP project id or number to which the target instance belongs.
47-
proj_instance: Customer ID (uuid with dashes) for the Chronicle instance.
48-
proj_region: region in which the target project is located.
49-
event_id: The ID of the event to retrieve.
44+
Args:
45+
http_session: Authorized session for HTTP requests.
46+
proj_id: GCP project id or number to which the target instance belongs.
47+
proj_instance: Customer ID (uuid with dashes) for the Chronicle instance.
48+
proj_region: region in which the target project is located.
49+
event_id: The ID of the event to retrieve.
5050
51-
Raises:
52-
requests.exceptions.HTTPError: HTTP request resulted in an error
53-
(response.status_code >= 400).
51+
Raises:
52+
requests.exceptions.HTTPError: HTTP request resulted in an error
53+
(response.status_code >= 400).
5454
55-
Requires the following IAM permission on the parent resource:
56-
chronicle.events.get
57-
"""
55+
Requires the following IAM permission on the parent resource:
56+
chronicle.events.get
57+
"""
5858
# URL encode the event_id in Base64
5959
encoded_event_id = base64.urlsafe_b64encode(event_id.encode()).decode()
6060
base_url_with_region = regions.url_always_prepend_region(

sdk/commands/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
"""Common utilities for CLI commands."""
22

3-
import os
43
from functools import wraps
4+
import os
55

66
import click
77
from dotenv import load_dotenv

search/v1alpha/udm_events_find.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@ def find_udm_events(http_session: requests.AuthorizedSession,
5959
tokens: Optional[List[str]] = None,
6060
event_ids: Optional[List[str]] = None,
6161
return_unenriched_data: bool = False,
62-
return_all_events_for_log: bool = False) -> None:
62+
return_all_events_for_log: bool = False
63+
) -> None:
64+
# pylint: disable=line-too-long
6365
"""Find UDM events in Chronicle using the Legacy Find UDM Events API.
6466
6567
Args:
@@ -80,12 +82,12 @@ def find_udm_events(http_session: requests.AuthorizedSession,
8082
Requires the following IAM permission on the parent resource:
8183
chronicle.events.batchGet
8284
"""
85+
# pylint: enable=line-too-long
8386
base_url_with_region = regions.url_always_prepend_region(
8487
CHRONICLE_API_BASE_URL, proj_region)
85-
# pylint: disable=line-too-long
88+
# pylint: disable=line-too-long-next
8689
instance = f"projects/{proj_id}/locations/{proj_region}/instances/{proj_instance}"
8790
url = f"{base_url_with_region}/v1alpha/{instance}/legacy:legacyFindUdmEvents"
88-
# pylint: enable=line-too-long
8991

9092
# Build query parameters
9193
params = []

0 commit comments

Comments
 (0)