Skip to content

Commit 3dc130c

Browse files
committed
Format the code correctly
1 parent d524b0b commit 3dc130c

File tree

6 files changed

+12
-9
lines changed

6 files changed

+12
-9
lines changed

src/base/clickhouse_kafka_sender.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def __init__(self, table_name: str):
2929
def insert(self, data: dict):
3030
"""
3131
Produces the insert operation to Kafka.
32-
32+
3333
Args:
3434
data (dict): content to write into the Kafka queue
3535
"""

src/base/data_classes/batch.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ class Batch:
1111
"""
1212
Class definition of a batch, used to divide the log input into smaller amounts
1313
"""
14+
1415
batch_id: uuid.UUID = field(
1516
metadata={"marshmallow_field": marshmallow.fields.UUID()}
1617
)

src/base/kafka_handler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ def _all_topics_created(self, topics) -> bool:
291291
Args:
292292
topics (list): List of topics to check
293293
Returns:
294-
bool
294+
bool
295295
"""
296296
number_of_retries_left = 30
297297
all_topics_created = False

src/inspector/inspector.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,9 @@ def _inspect_multivariate(self, model: str):
347347
logger.debug(f"Load Model: {model['model']} from {model['module']}.")
348348
if not model["model"] in VALID_MULTIVARIATE_MODELS:
349349
logger.error(f"Model {model} is not a valid multivariate model.")
350-
raise NotImplementedError(f"Model {model} is not a valid multivariate model.")
350+
raise NotImplementedError(
351+
f"Model {model} is not a valid multivariate model."
352+
)
351353

352354
module = importlib.import_module(model["module"])
353355
module_model = getattr(module, model["model"])

src/logcollector/batch_handler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ def _send_batch_for_key(self, key: str) -> None:
448448
Send one batch based on the key
449449
450450
Args:
451-
key (str): Key to identify the batch
451+
key (str): Key to identify the batch
452452
"""
453453
try:
454454
data = self.batch.complete_batch(key)

src/monitoring/clickhouse_batch_sender.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class Table:
3434
def verify(self, data: dict[str, Any]):
3535
"""
3636
Verify if the data has the correct columns and types.
37-
37+
3838
Args:
3939
data (dict): The values for each cell
4040
"""
@@ -190,11 +190,11 @@ def __del__(self):
190190
def add(self, table_name: str, data: dict[str, Any]):
191191
"""
192192
Adds the data to the batch for the table. Verifies the fields first.
193-
194-
Args:
193+
194+
Args:
195195
table_name (str): Name of the table to add data to
196196
data (dict): The values for each cell in the table
197-
197+
198198
"""
199199
self.tables.get(table_name).verify(data)
200200
self.batch.get(table_name).append(list(data.values()))
@@ -207,7 +207,7 @@ def add(self, table_name: str, data: dict[str, Any]):
207207
def insert(self, table_name: str):
208208
"""
209209
Inserts the batch for the given table.
210-
210+
211211
Args:
212212
table_name (str): Name of the table to insert data to
213213
"""

0 commit comments

Comments
 (0)