Skip to content

Commit

Permalink
Merge pull request #416 from matchalunatic/support-sha256-hashes
Browse files Browse the repository at this point in the history
Support SHA256 hashes
  • Loading branch information
takluyver authored Jul 4, 2021
2 parents 7cc5279 + 10e3145 commit d9f33ae
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions flit/upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,7 @@ def upload_file(file:Path, metadata:Metadata, repo):
content = f.read()
files = {'content': (file.name, content)}
data['md5_digest'] = hashlib.md5(content).hexdigest()
data['sha256_digest'] = hashlib.sha256(content).hexdigest()

log.info('Uploading %s...', file)
resp = requests.post(repo['url'],
Expand Down

0 comments on commit d9f33ae

Please sign in to comment.