-
Notifications
You must be signed in to change notification settings - Fork 296
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
[FIX] Missing report output - #1339 #1346
Conversation
See issue #1339 Previous version failed if 'anat', 'fmap', 'func', 'dwi' strings were found in file path, for example ses-noanatomicals. Changed to name of parent folder of source_file (requires valid BIDS structure).
Thanks for opening this pull request! We have detected this is the first time for you to contribute to fMRIPrep. Please check out our contributing guidelines.
Of course, if you want to opt-out this time there is no problem at all with adding your name later. You will be always welcome to add it in the future whenever you feel it should be listed. |
Thanks for this! I think it should be okay, but I'll try to have a more critical look at some point today. |
Hi @kasbohm, thanks a lot for this contribution. I've just submitted a PR to your branch adding a doctest for the test-case you are fixing. It will also synchronize with master (so we should not see the red cross for ds005 anymore). Please also confirm if you want to add your name to the .zenodo.json file. Thanks very much! |
I could've pushed to your branch directly, but I preferred the PR route. My PR is for adding a new test-case that your PR is fixing. As a side effect, it will resync your branch with master. But the relevant part is the new test. So please, merge the PR in so the new test is run with your patch.
This is really your decision. There is no commitment if you opt-in, although some people prefer to opt-out. If you opt-in, please add your name as indicated above. |
Add doctest + resync to master
Thanks for merging!. Now we will wait for the test_pytest build. If this PR works as promised (and I agree with Chris that it seems it will), then this should not fail anymore. |
The test passed, merging in. |
Fixes #1339
The previous version failed on edge cases where 'anat', 'fmap', 'func', 'dwi' strings were found in the file path, for example, if a session was named ses-noanatomicals. Output files were then placed wrongly.
Changes proposed in this pull request
Proposed small change to how mod is set (to the name of parent folder of self.inputs.source_file). This requires valid BIDS structure, but I assume that can be assumed.
Are there cases where self.inputs.source_file can be something other than 'anat', 'fmap', 'func', 'dwi' so we need to create exceptions/tests for that?