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

bidspath example contains runtimewarning #829

Closed
sappelhoff opened this issue Jul 6, 2021 · 3 comments · Fixed by #831
Closed

bidspath example contains runtimewarning #829

sappelhoff opened this issue Jul 6, 2021 · 3 comments · Fixed by #831
Labels
Milestone

Comments

@sappelhoff
Copy link
Member

https://mne.tools/mne-bids/dev/auto_examples/bidspath.html#bidspath-example

/home/circleci/project/mne_bids/path.py:587: RuntimeWarning: Could not locate a data file of a supported format. This is likely a problem with your BIDS dataset. Please run the BIDS validator on your data. (root=my_bids_root, basename=sub-123_ses-test). []
warn(msg)

and there are 2 more of those. At least it should be discussed in the example why there is such a warning.

@sappelhoff sappelhoff added the doc label Jul 6, 2021
@sappelhoff sappelhoff added this to the 0.8 milestone Jul 8, 2021
@sappelhoff
Copy link
Member Author

this is related to #712 #721 and the fetching behavior of BIDSPath.fpath

@hoechenberger
Copy link
Member

Shall we finally kill off all the BIDSPath "trying to guess what the user meant" magic? :)

@sappelhoff
Copy link
Member Author

Shall we finally kill off all the BIDSPath "trying to guess what the user meant" magic? :)

yes 💯 Let's do it in 0.9 🙏

sappelhoff added a commit to sappelhoff/mne-bids that referenced this issue Jul 13, 2021
hoechenberger pushed a commit that referenced this issue Jul 14, 2021
* fix doctests in path.py

* test: use pytest --doctest-modules

* fix some more examples

* make use of _write_json instead of json.dump

* fix fine-calib and crosstalk doctest

* DATA: add tiny_bids test dataset ~800kb

* fix all doctests using new test ds

* add code for generating tiny_bids

* fix example, sphinx warning

* use tiny_bids in bidspath example, fix #829

* write TSV files with newline character

* add missing newlines at end of files

* do not run pytest on examples

we did not do that before either, but --doctest-modules is now ON

and that option apparently also runs the examples

* add whatsnew for TSV line end

* properly ignore examples in pytest

* fix head_to_mri upstream API change

* xfail doctest on windows due to / vs \

* BIDSPath __str__ always .as_posix()

* fix op.join -> Path

* root in __repr__ --> posix path or None

* circumvent bids_path.root __str__

* 1) fix pep, 2) fix type hints, 3) fix example ds

* fix type hint

* I should run make pep before pushing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants