easydata
easydata copied to clipboard
Error on first fetch
With hash_value=None it should compute the hash and store it. It's expecting a value anyway...
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-19-de405f1e2b45> in <module>
----> 1 dsrc.fetch()
.../src/data/datasets.py in fetch(self, fetch_path, force)
905 self.fetched_ = True
906 for key, item in self.file_dict.items():
--> 907 status, result, hash_value = fetch_file(**item, force=force)
908 logger.debug(f"Fetching {key}: status:{status}")
909 if status: # True (cached) or HTTP Code (successful download)
.../src/data/fetch.py in fetch_file(url, contents, file_name, dst_dir, force, source_file, hash_type, hash_value, fetch_action, message, **kwargs)
292 else: # hash_type is not None
293 old_hash_type = hash_type
--> 294 hash_type, _ = hash_value.split(":")
295 if hash_type != old_hash_type:
296 logger.warning(f"Conflicting hash_type and hash_value. Using {hash_type}")
AttributeError: 'NoneType' object has no attribute 'split'