Skip to content
Snippets Groups Projects
Commit 6e233328 authored by Renzo Frigato's avatar Renzo Frigato
Browse files

change path generation for the CAS storage

parent 2f15b070
No related branches found
No related tags found
No related merge requests found
......@@ -93,7 +93,7 @@ def path_from_hash(hash_):
0/1/b/3/9/5/a/1/v0-sha384-01b395a1cbc0f218
"""
hash_version, hash_alg, actual_hash = hash_.split('-')
path = [actual_hash[i] for i in xrange(8)]
path = [hash_version, hash_alg] + [actual_hash[2 * i : 2 * i + 2] for i in range(3)]
path.append(hash_)
return os.path.join(*path)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment