Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/git_workflow_process.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ jobs:
run: |
git add .
git commit -m "Apply automatic formatting with Black and isort"
git push https://x-access-token:${{secrets.BFI_BOT_TOKEN}}@github.com/${{ github.repository }} HEAD:${{ github.head_ref || github.ref_name }}

- name: Check if PR exists
id: check-pr
Expand Down
13 changes: 7 additions & 6 deletions checksum_speed_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ def crc_4096(file):
buffr = afile.read(buffersize)
return format(crcvalue & 0xFFFFFFFF, "08x")

except Exception:
except Exception as err:
print(err)
return None


Expand All @@ -62,7 +63,8 @@ def md5_4096(file):
hash_md5.update(chunk)
return hash_md5.hexdigest()

except Exception:
except Exception and err:
print(err)
return None


Expand All @@ -80,7 +82,8 @@ def crc_65536(file):
buffr = afile.read(buffersize)
return format(crcvalue & 0xFFFFFFFF, "08x")

except Exception:
except Exception as error:
print(f"This is our error: {error}")
return None


Expand All @@ -101,9 +104,7 @@ def md5_65536(file):

def main():
if len(sys.argv) < 2:
print(
"Please remember to supply a file name to run size checks against:\npython3 checksum.py /path_to_file/video.mkv"
)
print("Please remember to supply a file name to run size checks against:\npython3 checksum.py /path_to_file/video.mkv")
else:
filepath = sys.argv[1]
if not (os.path.isfile(filepath)):
Expand Down
Loading