diff --git a/js/nostr/watchHistory.js b/js/nostr/watchHistory.js index c2367db9..4eac5c01 100644 --- a/js/nostr/watchHistory.js +++ b/js/nostr/watchHistory.js @@ -1486,6 +1486,7 @@ class WatchHistoryManager { devLogger.warn("[nostr] Unable to build watch history payload for month.", { actor: actorKey, monthIdentifier, + recordId: snapshotId, }); return { ok: false, error: "invalid-month", retryable: false }; } @@ -1516,7 +1517,7 @@ class WatchHistoryManager { } devLogger.info("[nostr] Preparing to publish watch history snapshot.", { actor: actorKey, - snapshotId, + recordId: snapshotId, monthIdentifier, itemCount: canonicalItems.length, payloadCount: Array.isArray(payload.items) ? payload.items.length : 0, @@ -1619,7 +1620,7 @@ class WatchHistoryManager { const tryEncryptWithCandidate = async (candidate, plaintext, context = {}) => { const details = { actor: actorKey, - snapshotId, + recordId: snapshotId, monthIdentifier, payloadSize: plaintext.length, scheme: candidate.scheme, @@ -2401,6 +2402,8 @@ class WatchHistoryManager { const ciphertext = typeof event.content === "string" ? event.content : ""; const ciphertextPreview = ciphertext.slice(0, 32); const chunkContext = { + recordId: snapshotId, + month: snapshotId, eventId: event.id ?? null, }; const availableSchemes = Array.from(decryptorCandidates.keys()); diff --git a/js/nostrEventSchemas.js b/js/nostrEventSchemas.js index 751cbb92..dab3a351 100644 --- a/js/nostrEventSchemas.js +++ b/js/nostrEventSchemas.js @@ -370,7 +370,7 @@ const BASE_SCHEMAS = { }, [NOTE_TYPES.WATCH_HISTORY_CHUNK]: { type: NOTE_TYPES.WATCH_HISTORY_CHUNK, - label: "Watch history month payload", + label: "Watch history monthly payload", kind: WATCH_HISTORY_KIND, identifierTag: { name: "d",