-
Notifications
You must be signed in to change notification settings - Fork 552
Open
Description
When trying to bump workerd in workers-sdk we noticed failires in the Vitest integration on Windows: cloudflare/workers-sdk#9757.
Vitest tries to clean up the persistent storage files for emulated resources such as KV, R2, etc. This storage is implemented via sqlite DOs. Before cleaning up Vitest runs a Worker that calls abortAllDurableObjects().
import workerdUnsafe from "workerd:unsafe";
export default {
async fetch(request) {
if (request.method !== "DELETE") return new Response(null, { status: 405 });
await workerdUnsafe.abortAllDurableObjects();
return new Response(null, { status: 204 });
}
};It then tries to delete the underlying sqlite db files.
After this version of workerd, the files that used by the DO storage are not released as expected on Windows resulting in EBUSY errors.
We have worked around this by adding a catch block for now. But it would be good to know if there was a problem with how worked releases file handles on Windows.
I'll try to create a workerd only reproduction.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels