Skip to content

Commit 7eb8981

Browse files
committed
lint
1 parent e3cdc3b commit 7eb8981

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

dynatrace_extension/sdk/communication.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@ def send_metrics(self, mint_lines: list[str]) -> list[MintResponse]:
402402
response = request(
403403
"POST",
404404
f"http://localhost:{self.local_ingest_port}/metrics/ingest",
405-
body='\n'.join(lines).encode(),
405+
body="\n".join(lines).encode(),
406406
headers={"Content-Type": CONTENT_TYPE_PLAIN},
407407
).json()
408408
mint_response = MintResponse.from_json(response)

dynatrace_extension/sdk/snapshot.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,11 @@ def find_log_dir() -> Path:
194194
if line.startswith("LogDir"):
195195
log_dir = line.split("=")[1].strip()
196196
if not log_dir:
197-
return Path(os.path.expandvars("%PROGRAMDATA%") + "/dynatrace/oneagent/log") if os.name == "nt" else Path("/var/log/dynatrace/oneagent")
197+
return (
198+
Path(os.path.expandvars("%PROGRAMDATA%") + "/dynatrace/oneagent/log")
199+
if os.name == "nt"
200+
else Path("/var/log/dynatrace/oneagent")
201+
)
198202
return Path(log_dir)
199203
msg = f"Could not find LogDir in {installation_conf}"
200204
raise Exception(msg)

0 commit comments

Comments
 (0)