Functions download throwing rust error on windows PC
Describe the bug Currently trying to download a function from my Supabase project and it's throwing a strange error no matter what I do
Error states:
thread 'main' panicked at crates/sb_graph/lib.rs:144:61:
called Result::unwrap() on an Err value: StripPrefixError(())
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
error running container: exit 101
Try rerunning the command with --debug to troubleshoot the error.
To Reproduce Steps to reproduce the behavior:
- init and login to supabase cli
- download function from online project
- error throws
Expected behavior The function is downloaded locally
Screenshots
Desktop (please complete the following information):
- OS: Win 11
- Version of CLI v 1.131.3
Could you run supabase functions download userAdd --create-ticket to send a crash report? It helps us collect context information to help reproduce.
Note: This is probably due to a Windows path separator being in the argument.
https://github.com/supabase/cli/blob/main/internal/functions/download/download.go#L169 https://github.com/supabase/edge-runtime/blob/main/crates/sb_graph/lib.rs#L144
fn main() {
let x = Path::new("\\aaa\\aa");
dbg!(x.strip_prefix("/"));
}
[src/main.rs:6] x.strip_prefix("/") = Err(
StripPrefixError(
(),
),
)