Skip to content

Commit

Permalink
Fix code that assigns url unnecessarily
Browse files Browse the repository at this point in the history
The dataset-level URL field should only be populated if the dataset
is a datalad dataset, which would make the 'Download with Dataset'
button show up in a catalog page.
  • Loading branch information
tmheunis committed Apr 16, 2024
1 parent 7be4d66 commit 1aeeb81
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion code/process_subdirectory.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,11 @@
"identifier": subds_id,
"version": subds_version,
"path_posix": subds_path,
"url": subds_url,
}
# Only include URL if it is a datalad dataset
if args.dataset_type == "datalad":
subdataset["url"] = subds_url

# 3. Now add subdataset record to the superdataset tabby file at
# '<superdataset>.datalad/tabby/self/subdatasets@tby-abcdjv0.tsv'
# - First get the home page tabby record
Expand Down

0 comments on commit 1aeeb81

Please sign in to comment.