diff --git a/deno.json b/deno.json index 964490c6..0c41a378 100644 --- a/deno.json +++ b/deno.json @@ -30,7 +30,8 @@ "@isaacs/ttlcache": "npm:@isaacs/ttlcache@^1.4.1", "@lambdalisue/async": "jsr:@lambdalisue/async@^2.1.1", "@noble/secp256k1": "npm:@noble/secp256k1@^2.0.0", - "@nostrify/nostrify": "jsr:@nostrify/nostrify@^0.29.0", + "@nostrify/db": "jsr:@nostrify/db@^0.30.0", + "@nostrify/nostrify": "jsr:@nostrify/nostrify@^0.30.0", "@scure/base": "npm:@scure/base@^1.1.6", "@sentry/deno": "https://deno.land/x/sentry@7.112.2/index.mjs", "@soapbox/kysely-deno-sqlite": "jsr:@soapbox/kysely-deno-sqlite@^2.1.0", diff --git a/deno.lock b/deno.lock index 5b403d44..101362a4 100644 --- a/deno.lock +++ b/deno.lock @@ -11,10 +11,12 @@ "jsr:@gleasonator/policy@0.4.1": "jsr:@gleasonator/policy@0.4.1", "jsr:@hono/hono@^4.4.6": "jsr:@hono/hono@4.5.3", "jsr:@lambdalisue/async@^2.1.1": "jsr:@lambdalisue/async@2.1.1", + "jsr:@nostrify/db@^0.30.0": "jsr:@nostrify/db@0.30.0", "jsr:@nostrify/nostrify@^0.22.1": "jsr:@nostrify/nostrify@0.22.5", "jsr:@nostrify/nostrify@^0.22.4": "jsr:@nostrify/nostrify@0.22.4", "jsr:@nostrify/nostrify@^0.22.5": "jsr:@nostrify/nostrify@0.22.5", - "jsr:@nostrify/nostrify@^0.29.0": "jsr:@nostrify/nostrify@0.29.0", + "jsr:@nostrify/nostrify@^0.30.0": "jsr:@nostrify/nostrify@0.30.0", + "jsr:@nostrify/types@^0.30.0": "jsr:@nostrify/types@0.30.0", "jsr:@soapbox/kysely-deno-sqlite@^2.1.0": "jsr:@soapbox/kysely-deno-sqlite@2.2.0", "jsr:@soapbox/stickynotes@^0.4.0": "jsr:@soapbox/stickynotes@0.4.0", "jsr:@std/assert@^0.217.0": "jsr:@std/assert@0.217.0", @@ -135,6 +137,15 @@ "@lambdalisue/async@2.1.1": { "integrity": "1fc9bc6f4ed50215cd2f7217842b18cea80f81c25744f88f8c5eb4be5a1c9ab4" }, + "@nostrify/db@0.30.0": { + "integrity": "a75ba78be89d57c54c3d47e9e94c7142817c5b50daec27bf7f9a4af4629be20b", + "dependencies": [ + "jsr:@nostrify/nostrify@^0.30.0", + "jsr:@nostrify/types@^0.30.0", + "npm:kysely@^0.27.3", + "npm:nostr-tools@^2.7.0" + ] + }, "@nostrify/nostrify@0.22.4": { "integrity": "1c8a7847e5773213044b491e85fd7cafae2ad194ce59da4d957d2b27c776b42d", "dependencies": [ @@ -164,21 +175,24 @@ "npm:zod@^3.23.8" ] }, - "@nostrify/nostrify@0.29.0": { - "integrity": "d0489b62441c891324cce60c14bb398013259494b5ad9d21ec6dfbf0ca7368c9", + "@nostrify/nostrify@0.30.0": { + "integrity": "7c29e7d8b5a0a81e238170ac1e7ad708bc72dd8f478d8d82c30598fb4eff9b9c", "dependencies": [ + "jsr:@nostrify/types@^0.30.0", "jsr:@std/crypto@^0.224.0", "jsr:@std/encoding@^0.224.1", "npm:@scure/base@^1.1.6", "npm:@scure/bip32@^1.4.0", "npm:@scure/bip39@^1.3.0", - "npm:kysely@^0.27.3", "npm:lru-cache@^10.2.0", "npm:nostr-tools@^2.7.0", "npm:websocket-ts@^2.1.5", "npm:zod@^3.23.8" ] }, + "@nostrify/types@0.30.0": { + "integrity": "1f38fa849cff930bd709edbf94ef9ac02f46afb8b851f86c8736517b354616da" + }, "@soapbox/kysely-deno-sqlite@2.2.0": { "integrity": "668ec94600bc4b4d7bd618dd7ca65d4ef30ee61c46ffcb379b6f45203c08517a", "dependencies": [ @@ -1808,7 +1822,8 @@ "jsr:@db/sqlite@^0.11.1", "jsr:@hono/hono@^4.4.6", "jsr:@lambdalisue/async@^2.1.1", - "jsr:@nostrify/nostrify@^0.29.0", + "jsr:@nostrify/db@^0.30.0", + "jsr:@nostrify/nostrify@^0.30.0", "jsr:@soapbox/kysely-deno-sqlite@^2.1.0", "jsr:@soapbox/stickynotes@^0.4.0", "jsr:@std/assert@^0.225.1", diff --git a/src/storages/EventsDB.ts b/src/storages/EventsDB.ts index 011f5a02..ba9e93a4 100644 --- a/src/storages/EventsDB.ts +++ b/src/storages/EventsDB.ts @@ -1,7 +1,7 @@ // deno-lint-ignore-file require-await +import { NDatabase } from '@nostrify/db'; import { - NDatabase, NIP50, NKinds, NostrEvent, diff --git a/src/test.ts b/src/test.ts index 5156d3ff..c3c0db7b 100644 --- a/src/test.ts +++ b/src/test.ts @@ -2,9 +2,10 @@ import fs from 'node:fs/promises'; import path from 'node:path'; import { Database as Sqlite } from '@db/sqlite'; +import { NDatabase } from '@nostrify/db'; +import { NostrEvent } from '@nostrify/nostrify'; import { DenoSqlite3Dialect } from '@soapbox/kysely-deno-sqlite'; import { finalizeEvent, generateSecretKey } from 'nostr-tools'; -import { NDatabase, NostrEvent } from '@nostrify/nostrify'; import { FileMigrationProvider, Kysely, Migrator } from 'kysely'; import { PostgresJSDialect, PostgresJSDialectConfig } from 'kysely-postgres-js'; import postgres from 'postgres';