Skip to content

Commit 3cda1e3

Browse files
use datetime to detect local time zone
1 parent dbe83f4 commit 3cda1e3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mne_bids/read.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ def _handle_scans_reading(scans_fname, raw, bids_path):
407407
else:
408408
# if timezone is not set, assume machine's local timezone
409409
if acq_time.tzinfo is None:
410-
local_tz = datetime.now(timezone.utc).astimezone().tzinfo
410+
local_tz = datetime.now().astimezone().tzinfo
411411
acq_time = acq_time.replace(tzinfo=local_tz)
412412
# Convert time offset to UTC
413413
acq_time = acq_time.astimezone(timezone.utc)

0 commit comments

Comments
 (0)