File tree Expand file tree Collapse file tree 2 files changed +11
-8
lines changed
Expand file tree Collapse file tree 2 files changed +11
-8
lines changed Original file line number Diff line number Diff line change @@ -136,14 +136,15 @@ def _find_absolute_paths(
136136 def _normalize_path_list (
137137 lpaths : NestedSequence [str | os .PathLike ],
138138 ) -> NestedSequence [str ]:
139- return [
140- (
141- _normalize_path (p )
142- if isinstance (p , str | os .PathLike )
143- else _normalize_path_list (p )
144- )
145- for p in lpaths
146- ]
139+ paths = []
140+ for p in lpaths :
141+ if isinstance (p , str | os .PathLike ):
142+ paths .append (_normalize_path (p ))
143+ elif isinstance (p , list ):
144+ paths .append (_normalize_path_list (p )) # type: ignore[arg-type]
145+ else :
146+ paths .append (p ) # type: ignore[arg-type]
147+ return paths
147148
148149 return _normalize_path_list (paths )
149150
Original file line number Diff line number Diff line change @@ -5511,6 +5511,8 @@ def test_source_encoding_always_present_with_fsspec() -> None:
55115511 fs = fsspec .filesystem ("file" )
55125512 with fs .open (tmp ) as f , open_dataset (f ) as ds :
55135513 assert ds .encoding ["source" ] == tmp
5514+ with fs .open (tmp ) as f , open_mfdataset ([f ]) as ds :
5515+ assert "foo" in ds
55145516
55155517
55165518def _assert_no_dates_out_of_range_warning (record ):
You can’t perform that action at this time.
0 commit comments