Skip to content

Commit 8c1317f

Browse files
committed
add comment to explain use of str()
[skip ci]
1 parent 9c07a97 commit 8c1317f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

neo/io/nwbio.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -411,6 +411,7 @@ def _build_global_annotations(self, blocks):
411411
annotations["identifier"] = str(self.filename)
412412
if "session_description" not in annotations:
413413
annotations["session_description"] = blocks[0].description or str(self.filename)
414+
# need to use str() here because self.filename may be a pathlib path object
414415
# todo: concatenate descriptions of multiple blocks if different
415416
if annotations.get("session_start_time", None) is None:
416417
if "rec_datetime" in annotations:

0 commit comments

Comments
 (0)