Skip to content

Commit

Permalink
Merge pull request #994 from dandi/error
Browse files Browse the repository at this point in the history
Setting version to min version if not available
  • Loading branch information
yarikoptic authored May 2, 2022
2 parents b73f44d + ceac616 commit 1e3fbd4
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion dandi/bids_validator_xs.py
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,13 @@ def select_schema_dir(
schema_min_version,
)
schema_version = schema_min_version
if schema_min_version:
if not schema_version:
lgr.warning(
"No BIDSVersion could be found for the dataset. Falling back to %s.",
schema_min_version,
)
schema_version = schema_min_version
elif schema_min_version:
if schema_version < schema_min_version:
lgr.warning(
"BIDSVersion %s is less than the minimal working "
Expand Down

0 comments on commit 1e3fbd4

Please sign in to comment.