Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(adapters): cleanup sqlite3 + better-sqlite3 for libsql #10813

Merged
merged 16 commits into from
May 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions apps/dev/nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@
"dependencies": {
"@auth/prisma-adapter": "workspace:*",
"@prisma/client": "^5",
"next": "14.2.0-canary.47",
"next": "14.2.3",
"next-auth": "workspace:*",
"nodemailer": "^6.9.3",
"react": "^18",
"react-dom": "^18"
},
"devDependencies": {
"@libsql/client": "^0.6.0",
"@types/react": "^18.2.23",
"@types/react-dom": "^18.2.8",
"prisma": "^5",
"sqlite3": "^5.0.8"
"prisma": "^5"
}
}
2 changes: 1 addition & 1 deletion packages/adapter-d1/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,6 @@
"devDependencies": {
"@cloudflare/workers-types": "^4.20230321.0",
"@miniflare/d1": "^2.12.2",
"better-sqlite3": "^8.6.0"
"better-sqlite3": "^9.6.0"
}
}
3 changes: 1 addition & 2 deletions packages/adapter-drizzle/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,10 @@
"@auth/core": "workspace:*"
},
"devDependencies": {
"@types/better-sqlite3": "^7.6.4",
"@types/uuid": "^8.3.3",
"better-sqlite3": "^9.4.0",
"drizzle-kit": "^0.20.17",
"drizzle-orm": "^0.30.9",
"libsql": "^0.3.18",
"mysql2": "^3.9.7",
"postgres": "^3.4.3",
"tsx": "^4.7.0"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { AdapterAccountType } from "@auth/core/adapters"
import Database from "better-sqlite3"
import { drizzle } from "drizzle-orm/better-sqlite3"
import Database from "libsql"
import {
integer,
primaryKey,
Expand Down
2 changes: 1 addition & 1 deletion packages/adapter-drizzle/test/sqlite/schema.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { drizzle } from "drizzle-orm/better-sqlite3"
import Database from "better-sqlite3"
import Database from "libsql"
import { defineTables } from "../../src/lib/sqlite.ts"

export const {
Expand Down
3 changes: 1 addition & 2 deletions packages/adapter-kysely/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,9 @@
"kysely": "^0.26.1"
},
"devDependencies": {
"@types/better-sqlite3": "^7.6.3",
"@types/pg": "^8.6.5",
"better-sqlite3": "^8.6.0",
"kysely": "^0.24.2",
"libsql": "^0.3.18",
"mysql2": "^3.9.7",
"pg": "^8.10.0"
}
Expand Down
2 changes: 1 addition & 1 deletion packages/adapter-kysely/test/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
SqliteDialect,
} from "kysely"
import { createPool } from "mysql2"
import SqliteDatabase from "better-sqlite3"
import SqliteDatabase from "libsql"
import { KyselyAdapter, KyselyAuth } from "../src"
import type { Database } from "../src"

Expand Down
10 changes: 5 additions & 5 deletions packages/adapter-typeorm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,21 +48,24 @@
"@auth/core": "workspace:*"
},
"devDependencies": {
"libsql": "^0.3.18",
"mssql": "^7.2.1",
"mysql": "^2.18.1",
"pg": "^8.7.3",
"sqlite3": "^5.0.8",
"typeorm": "0.3.17",
"typeorm-naming-strategies": "^4.1.0"
},
"peerDependencies": {
"libsql": "^0.3.18",
"mssql": "^6.2.1 || ^7 || ^8 || ^9",
"mysql": "^2.18.1 || ^3",
"pg": "^8.2.1",
"sqlite3": "^5.0.2",
"typeorm": "^0.3.7"
},
"peerDependenciesMeta": {
"libsql": {
"optional": true
},
"mysql": {
"optional": true
},
Expand All @@ -71,9 +74,6 @@
},
"pg": {
"optional": true
},
"sqlite3": {
"optional": true
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as entities from "../custom-entities"
import { db } from "../helpers"

const sqliteConfig = {
type: "sqlite" as const,
type: "better-sqlite3" as const,
name: "next-auth-test-memory",
database: "./test/sqlite/dev.db",
synchronize: true,
Expand Down
2 changes: 1 addition & 1 deletion packages/adapter-typeorm/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
"rootDir": "src"
},
"exclude": ["*.js", "*.d.ts"],
"include": ["src/**/*"]
"include": ["src/*"]
}
2 changes: 1 addition & 1 deletion packages/utils/vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ export default defineConfig({
},
setupFiles: ["../utils/vitest-setup.ts"],
},
plugins: [swc.vite(), preact()],
plugins: [swc.vite(), preact({ include: ["**/*[jt]sx"] })],
})
Loading
Loading