Skip to content

Commit a1ba548

Browse files
committed
🩹 (helpers) Make sure to use sha1 for servicelayer archive
1 parent c9176de commit a1ba548

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

openaleph_procrastinate/helpers.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
from openaleph_procrastinate.settings import OpenAlephSettings
1717

1818
OPAL_ORIGIN = "openaleph_procrastinate"
19+
ARCHIVE_CHECKSUM_ALGORITHM = "sha1"
1920
settings = OpenAlephSettings()
2021
sqlalchemy_pool = {
2122
"pool_size": settings.db_pool_size,
@@ -43,7 +44,7 @@ def open_file(dataset: str, content_hash: str) -> ContextManager[VirtualIO]:
4344
"""
4445
archive = get_archive()
4546
key = lookup_key(content_hash)
46-
return archive.local_open(key)
47+
return archive.local_open(key, algorithm=ARCHIVE_CHECKSUM_ALGORITHM)
4748

4849

4950
def load_entity(dataset: str, entity_id: str) -> EntityProxy:

0 commit comments

Comments
 (0)