WatermelonDB icon indicating copy to clipboard operation
WatermelonDB copied to clipboard

In a Node.js environment, throws a resource lock error.

Open KotoriMinami opened this issue 1 year ago • 4 comments

My basic code is as follows.

import { mySchema } from './model/schema.js'

import SQLiteAdapter from "@nozbe/watermelondb/adapters/sqlite/index.js";

const adapter = new SQLiteAdapter({
    dbName: 'test',
    schema: mySchema,
    onSetUpError: error => {
        // Database failed to load -- offer the user to reload the app or log out
        console.log(error)
    }
})

At this point, running the code produces the following results. image How should it be handled?

KotoriMinami avatar Nov 13 '23 07:11 KotoriMinami