Skip to content

Commit 25b0520

Browse files
[POLISH] Replaces time.time with time.perf_counter
1 parent 75cf808 commit 25b0520

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

locstat/__main__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ def main() -> int:
129129
"depth": args.max_depth,
130130
}
131131
output_mapping = {}
132-
epoch: float = time.time()
132+
epoch: float = time.perf_counter()
133133
if args.verbosity == Verbosity.BARE:
134134
line_data: array = array("L", (0, 0, 0))
135135
parse_directory(**kwargs, line_data=line_data)
@@ -164,7 +164,7 @@ def main() -> int:
164164
output_mapping[OutputKeys.LANGUAGES] = language_record
165165

166166
general_metadata: dict[str, str] = {
167-
OutputKeys.TIME: f"{time.time()-epoch:.3f}s",
167+
OutputKeys.TIME: f"{time.perf_counter()-epoch:.3f}s",
168168
OutputKeys.SCANNED_AT: datetime.now().strftime("%d/%m/%y, at %H:%M:%S"),
169169
OutputKeys.PLATFORM: platform.system(),
170170
}

0 commit comments

Comments
 (0)