1
0
mirror of https://github.com/ciromattia/kcc synced 2026-06-22 22:35:23 +00:00

Revert "huge speed optimization on HDD by removing md5 (#845)"

This reverts commit 01625904d1.
This commit is contained in:
Alex Xu
2025-03-06 13:54:11 -08:00
committed by GitHub
parent 24ab72fcbc
commit 46a6103e19
3 changed files with 18 additions and 16 deletions
+10
View File
@@ -75,6 +75,16 @@ def walkLevel(some_dir, level=1):
del dirs[:]
def md5Checksum(fpath):
with open(fpath, 'rb') as fh:
m = md5()
while True:
data = fh.read(8192)
if not data:
break
m.update(data)
return m.hexdigest()
def sanitizeTrace(traceback):
return ''.join(format_tb(traceback))\