Skip to content

Commit

Permalink
c
Browse files Browse the repository at this point in the history
  • Loading branch information
nameexhaustion committed Jun 26, 2024
1 parent ffe9294 commit 027affc
Showing 1 changed file with 23 additions and 6 deletions.
29 changes: 23 additions & 6 deletions crates/polars-lazy/src/scan/file_list_reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,19 +117,36 @@ fn expand_paths(
.list(Some(&prefix))
.map(|x| {
x.map(|x| {
PathBuf::from(format_path(
&cloud_location.scheme,
&cloud_location.bucket,
x.location.as_ref(),
))
PathBuf::from({
#[cfg(not(target_family = "windows"))]
{
format_path(
&cloud_location.scheme,
&cloud_location.bucket,
x.location.as_ref(),
)
}
#[cfg(target_family = "windows")]
{
x.location.to_string()
}
})
})
})
.try_collect::<Vec<_>>()
.await
.map_err(to_compute_err)?;

paths.sort_unstable();
(prefix.as_ref().len(), paths)
(
format_path(
&cloud_location.scheme,
&cloud_location.bucket,
&cloud_location.prefix,
)
.len(),
paths,
)
};

PolarsResult::Ok(out)
Expand Down

0 comments on commit 027affc

Please sign in to comment.