Skip to content

Commit 0ae366e

Browse files
committed
Fix up solution
1 parent c8494d8 commit 0ae366e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

solutions/validate_data.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
python3 scripts/validata_data.py data
66
"""
77

8-
import os
8+
import op as op
99
import sys
1010
import hashlib
1111

@@ -48,11 +48,11 @@ def validate_data(data_directory):
4848
``data_hashes.txt`` file.
4949
"""
5050
# Read lines from ``data_hashes.txt`` file.
51-
for line in open(os.path.join(data_directory, 'data_hashes.txt'), 'rt'):
51+
for line in open(op.join(data_directory, 'data_hashes.txt'), 'rt'):
5252
# Split into SHA1 hash and filename
5353
hash, filename = line.strip().split()
5454
# Calculate actual hash for given filename.
55-
actual_hash = file_hash(os.path.join(data_directory, filename))
55+
actual_hash = file_hash(op.join(data_directory, filename))
5656
# If hash for filename is not the same as the one in the file, raise
5757
# ValueError
5858
if hash != actual_hash:

0 commit comments

Comments
 (0)