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

account for optional Z in time strs #1240

Merged
merged 9 commits into from
Mar 25, 2024
2 changes: 2 additions & 0 deletions mne_bids/read.py
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,8 @@
if "." not in acq_time:
# acquisition time ends with '.%fZ' microseconds string
acq_time += ".0Z"
if "Z" not in acq_time:
hoechenberger marked this conversation as resolved.
Show resolved Hide resolved
acq_time += "Z"

Check warning on line 335 in mne_bids/read.py

View check run for this annotation

Codecov / codecov/patch

mne_bids/read.py#L335

Added line #L335 was not covered by tests
acq_time = datetime.strptime(acq_time, "%Y-%m-%dT%H:%M:%S.%fZ")
acq_time = acq_time.replace(tzinfo=timezone.utc)

Expand Down
Loading