Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for .bids-validator-config.json filename #3141

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

yarikoptic
Copy link
Contributor

We have a legitimate configuration for (legacy) bids-validation within dataset in .bids-validator-config.json .
git push was denied with no specific file mentioned but I guess it is because of that file.

We have a legitimate configuration for (legacy) bids-validation within dataset
in .bids-validator-config.json .
git push was denied with no specific file mentioned but I guess it is because of that file.
Copy link

codecov bot commented Sep 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 43.71%. Comparing base (2a391d3) to head (2538051).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3141      +/-   ##
==========================================
- Coverage   44.07%   43.71%   -0.37%     
==========================================
  Files         593      549      -44     
  Lines       37760    36153    -1607     
  Branches     1124     1158      +34     
==========================================
- Hits        16643    15803     -840     
+ Misses      20915    20159     -756     
+ Partials      202      191      -11     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@yarikoptic
Copy link
Contributor Author

Well, there seems to be quite a bit of logic linked to having .bidsignore file... I wonder if I should also add more on supporting .bids-validator-config.json? (e.g. .gitattributes config for it etc). Or may be it is somehow automatically disabled (e.g. a custom config provided to invocation of bids-validator)?

But in either case -- why to forbid other .dotfiles in general???? If I were on a mission to abuse openneuro I could stash my abusing materials under .datalad/ or smth like that which is ignored already.

@yarikoptic
Copy link
Contributor Author

yikes, tests fail with

........................................................................ [ 75%]
Fatal Python error: Segmentation fault

unrelated, filed

@effigies
Copy link
Contributor

effigies commented Sep 6, 2024

All this would do is not fail on the presence of this file. OpenNeuro will continue to pass its own configuration, so these files will not affect the validation of the dataset on OpenNeuro. Is your goal to override OpenNeuro's configuration? What are your use cases? I doubt we'd permit this.

@yarikoptic
Copy link
Contributor Author

yarikoptic commented Sep 6, 2024

All this would do is not fail on the presence of this file. OpenNeuro will continue to pass its own configuration, so these files will not affect the validation of the dataset on OpenNeuro.

that would be unfortunate but I think less critical -- most of them are warnings so we could ensure we are ignoring what we know is Ok and then would react on any new warning or error if they emerge.

here is the content of that file:

{
  "ignore": [
    "INCONSISTENT_PARAMETERS",
    "INCONSISTENT_SUBJECTS",
    "MISSING_SESSION",
    "STIMULUS_FILE_MISSING",
    "UNUSED_STIMULUS"
  ]
}

I really think that providing targetted configuration for validation is ways better than the current facilitated practice many folks adhere to - ignoring all tricky files via .bidsignore

check out those counts and note even a case of abuse of .bidsignore as a directory
$> wc -l ds*/.bidsignore | sort -n | nl | tail
wc: ds001583/.bidsignore: Is a directory
   245	     33 ds002041/.bidsignore
   246	     34 ds000108/.bidsignore
   247	     39 ds003684/.bidsignore
   248	     64 ds000240/.bidsignore
   249	     82 ds002320/.bidsignore
   250	     87 ds004475/.bidsignore
   251	    216 ds004808/.bidsignore
   252	    553 ds004505/.bidsignore
   253	   2674 ds000221/.bidsignore
   254	   4576 total

and cases like

$> cat ds000108/.bidsignore
sub-01/func
sub-02/func
...

@yarikoptic
Copy link
Contributor Author

@effigies @nellh @rwblair WDYT about a global solution to allow / use the provided .bids-validator-config.json? e.g.

  • where is the one you provide from openneuro? may be check could be added that if there is one provided in dataset, it should include what you require for openneuro?
  • validator could be made to consume multiple files and taking them as a union??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants