Closed fanoway closed 6 months ago
Hey there 👋🏻 . Seems like this is a Windows-specific error. Were you using one of the examples or do you have a reproduction repo so I can look into fixing this issue?
I think I managed to resolve the issue. The binary name resolving didn't include .exe
which is added on Windows. In case this issue is not resolved by using vercel-rust@4.0.0-beta.2
feel free to reopen.
Thanks. I am running windows 10 for reference.
I switched to the beta.2 version. and it resulted in the same error.
A bit more info for you. The rmeta dir its looking for does not exist, but there are other rmeta dirs with different names
My repo can be found here
Will have a look at it tomorrow
The project was missing a vercel.json
file (note that the glob in your initial post missed an *
). Also make sure to add target
to .vercelignore
to prevent uploading it.
{
"functions": {
"api/**/*.rs": {
"runtime": "vercel-rust@4.0.0-beta.2"
}
}
}
After applying the above I could not reproduce the error when running vercel dev
.
$ rustup show
Default host: aarch64-pc-windows-msvc
rustup home: C:\Users\ecklf\.rustup
stable-aarch64-pc-windows-msvc (default)
rustc 1.68.0 (2c8cc3432 2023-03-06)
My handlers build and work properly when using vercel deploy. However using the local vercel dev results in the following error. The target\release\deps directory exists, however the rmetaXXXXX file does not, other files exist with a similair but different name.
[Error: ENOENT: no such file or directory, scandir 'C:\Users\user-name\Documents\project-name\target\release\deps\rmeta8XbjCX'] { errno: -4058, code: 'ENOENT', syscall: 'scandir', path: 'C:\\Users\\user-name\\Documents\\project-name\\target\\release\\deps\\rmeta8XbjCX' }
My vercel.json file looks like
{ "functions": { "api/*/*.rs": { "runtime": "vercel-rust@4.0.0-beta.1" } } }