From dc749b1ee1f247fea53763aedf9609305f5f6157 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vojt=C4=9Bch=20Jungmann?= Date: Tue, 2 May 2023 13:30:35 +0200 Subject: [PATCH 1/3] feat: upgrade prisma --- packages/database/package.json | 4 ++-- packages/tests/package.json | 2 +- packages/usersplit/package.json | 2 +- pnpm-lock.yaml | 38 ++++++++++++++++----------------- 4 files changed, 23 insertions(+), 23 deletions(-) diff --git a/packages/database/package.json b/packages/database/package.json index 8e14a62..12d456b 100644 --- a/packages/database/package.json +++ b/packages/database/package.json @@ -9,11 +9,11 @@ "db:deploy": "prisma migrate deploy" }, "dependencies": { - "@prisma/client": "^4.11.0", + "@prisma/client": "^4.13.0", "bcrypt": "^5.1.0" }, "devDependencies": { - "prisma": "^4.11.0", + "prisma": "^4.13.0", "ts-node": "^10.9.1", "@types/bcrypt": "^5.0.0" }, diff --git a/packages/tests/package.json b/packages/tests/package.json index 1c3df61..61e5f1b 100644 --- a/packages/tests/package.json +++ b/packages/tests/package.json @@ -7,7 +7,7 @@ }, "dependencies": { "@testy/database": "workspace:*", - "@prisma/client": "^4.11.0", + "@prisma/client": "^4.13.0", "jest-mock-extended": "^3.0.3", "vitest": "^0.29.7" }, diff --git a/packages/usersplit/package.json b/packages/usersplit/package.json index cd1d140..fcc88dc 100644 --- a/packages/usersplit/package.json +++ b/packages/usersplit/package.json @@ -11,7 +11,7 @@ "ts-node": "^10.9.1" }, "devDependencies": { - "prisma": "^4.11.0", + "prisma": "^4.13.0", "ts-node": "^10.9.1", "@types/bcrypt": "^5.0.0" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2b29cf2..6d1fc6e 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -124,8 +124,8 @@ importers: packages/database: dependencies: '@prisma/client': - specifier: ^4.11.0 - version: 4.11.0(prisma@4.11.0) + specifier: ^4.13.0 + version: 4.13.0(prisma@4.13.0) bcrypt: specifier: ^5.1.0 version: 5.1.0 @@ -134,8 +134,8 @@ importers: specifier: ^5.0.0 version: 5.0.0 prisma: - specifier: ^4.11.0 - version: 4.11.0 + specifier: ^4.13.0 + version: 4.13.0 ts-node: specifier: ^10.9.1 version: 10.9.1(@types/node@18.15.5)(typescript@5.0.4) @@ -170,8 +170,8 @@ importers: packages/tests: dependencies: '@prisma/client': - specifier: ^4.11.0 - version: 4.11.0(prisma@4.11.0) + specifier: ^4.13.0 + version: 4.13.0(prisma@4.13.0) '@testy/database': specifier: workspace:* version: link:../database @@ -254,8 +254,8 @@ importers: specifier: ^5.0.0 version: 5.0.0 prisma: - specifier: ^4.11.0 - version: 4.11.0 + specifier: ^4.13.0 + version: 4.13.0 packages: @@ -1168,8 +1168,8 @@ packages: /@polka/url@1.0.0-next.21: resolution: {integrity: sha512-a5Sab1C4/icpTZVzZc5Ghpz88yQtGOyNqYXcZgOssB2uuAr+wF/MvN6bgtW32q7HHrvBki+BsZ0OuNv6EV3K9g==} - /@prisma/client@4.11.0(prisma@4.11.0): - resolution: {integrity: sha512-0INHYkQIqgAjrt7NzhYpeDQi8x3Nvylc2uDngKyFDDj1tTRQ4uV1HnVmd1sQEraeVAN63SOK0dgCKQHlvjL0KA==} + /@prisma/client@4.13.0(prisma@4.13.0): + resolution: {integrity: sha512-YaiiICcRB2hatxsbnfB66uWXjcRw3jsZdlAVxmx0cFcTc/Ad/sKdHCcWSnqyDX47vAewkjRFwiLwrOUjswVvmA==} engines: {node: '>=14.17'} requiresBuild: true peerDependencies: @@ -1178,16 +1178,16 @@ packages: prisma: optional: true dependencies: - '@prisma/engines-version': 4.11.0-57.8fde8fef4033376662cad983758335009d522acb - prisma: 4.11.0 + '@prisma/engines-version': 4.13.0-50.1e7af066ee9cb95cf3a403c78d9aab3e6b04f37a + prisma: 4.13.0 dev: false - /@prisma/engines-version@4.11.0-57.8fde8fef4033376662cad983758335009d522acb: - resolution: {integrity: sha512-3Vd8Qq06d5xD8Ch5WauWcUUrsVPdMC6Ge8ILji8RFfyhUpqon6qSyGM0apvr1O8n8qH8cKkEFqRPsYjuz5r83g==} + /@prisma/engines-version@4.13.0-50.1e7af066ee9cb95cf3a403c78d9aab3e6b04f37a: + resolution: {integrity: sha512-fsQlbkhPJf08JOzKoyoD9atdUijuGBekwoOPZC3YOygXEml1MTtgXVpnUNchQlRSY82OQ6pSGQ9PxUe4arcSLQ==} dev: false - /@prisma/engines@4.11.0: - resolution: {integrity: sha512-0AEBi2HXGV02cf6ASsBPhfsVIbVSDC9nbQed4iiY5eHttW9ZtMxHThuKZE1pnESbr8HRdgmFSa/Kn4OSNYuibg==} + /@prisma/engines@4.13.0: + resolution: {integrity: sha512-HrniowHRZXHuGT9XRgoXEaP2gJLXM5RMoItaY2PkjvuZ+iHc0Zjbm/302MB8YsPdWozAPHHn+jpFEcEn71OgPw==} requiresBuild: true /@rollup/plugin-commonjs@24.0.1(rollup@3.17.2): @@ -4086,13 +4086,13 @@ packages: react-is: 18.2.0 dev: false - /prisma@4.11.0: - resolution: {integrity: sha512-4zZmBXssPUEiX+GeL0MUq/Yyie4ltiKmGu7jCJFnYMamNrrulTBc+D+QwAQSJ01tyzeGHlD13kOnqPwRipnlNw==} + /prisma@4.13.0: + resolution: {integrity: sha512-L9mqjnSmvWIRCYJ9mQkwCtj4+JDYYTdhoyo8hlsHNDXaZLh/b4hR0IoKIBbTKxZuyHQzLopb/+0Rvb69uGV7uA==} engines: {node: '>=14.17'} hasBin: true requiresBuild: true dependencies: - '@prisma/engines': 4.11.0 + '@prisma/engines': 4.13.0 /process-warning@2.2.0: resolution: {integrity: sha512-/1WZ8+VQjR6avWOgHeEPd7SDQmFQ1B5mC1eRXsCm5TarlNmx/wCsa5GEaxGm05BORRtyG/Ex/3xq3TuRvq57qg==} From d6018f3f0bbb00e6050112399c1938b90e01c3e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vojt=C4=9Bch=20Jungmann?= Date: Tue, 2 May 2023 13:36:45 +0200 Subject: [PATCH 2/3] fix: remove prisma seed from wrong packages --- packages/tests/package.json | 3 --- packages/usersplit/package.json | 3 --- 2 files changed, 6 deletions(-) diff --git a/packages/tests/package.json b/packages/tests/package.json index 61e5f1b..6b9b4d5 100644 --- a/packages/tests/package.json +++ b/packages/tests/package.json @@ -14,8 +14,5 @@ "devDependencies": { "eslint-config-custom": "workspace:*", "ts-node": "^10.9.1" - }, - "prisma": { - "seed": "node --loader ts-node/esm prisma/seed.ts" } } diff --git a/packages/usersplit/package.json b/packages/usersplit/package.json index fcc88dc..3c18342 100644 --- a/packages/usersplit/package.json +++ b/packages/usersplit/package.json @@ -14,8 +14,5 @@ "prisma": "^4.13.0", "ts-node": "^10.9.1", "@types/bcrypt": "^5.0.0" - }, - "prisma": { - "seed": "node --loader ts-node/esm prisma/seed.ts" } } From 9a00a1d4a9b86dff6bf460e58df31aa0b19832e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vojt=C4=9Bch=20Jungmann?= Date: Tue, 2 May 2023 13:36:59 +0200 Subject: [PATCH 3/3] fix: prisma db:seed on node 20 --- packages/database/package.json | 2 +- packages/database/prisma/seed.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/database/package.json b/packages/database/package.json index 12d456b..6c2ba35 100644 --- a/packages/database/package.json +++ b/packages/database/package.json @@ -18,6 +18,6 @@ "@types/bcrypt": "^5.0.0" }, "prisma": { - "seed": "node --loader ts-node/esm prisma/seed.ts" + "seed": "ts-node prisma/seed.ts" } } diff --git a/packages/database/prisma/seed.ts b/packages/database/prisma/seed.ts index 9e67a14..f9c0745 100644 --- a/packages/database/prisma/seed.ts +++ b/packages/database/prisma/seed.ts @@ -1,5 +1,6 @@ import { PrismaClient } from '@prisma/client'; import bcrypt from 'bcrypt'; + const prisma = new PrismaClient(); async function main() {