Skip to content

Commit

Permalink
Always use the original file format when downloading files.
Browse files Browse the repository at this point in the history
Otherwise, the files will not have the correct hashes, as dataverse replaces, e.g., csv or R table files with its own tabular data format.

Closes #307.
  • Loading branch information
shoeffner committed Jul 17, 2024
1 parent 7d7d514 commit addbe3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion datalad_dataverse/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ def download_file(self, fid: int, path: Path):
# https://github.com/gdcc/pyDataverse/issues/49
# the code below is nevertheless readied for such a
# scenario
response = self.data_access_api.get_datafile(fid)
response = self.data_access_api.get_datafile(fid, data_format="original")
# http error handling
response.raise_for_status()
with path.open("wb") as f:
Expand Down

0 comments on commit addbe3c

Please sign in to comment.