openvibers/openvibe.reviews Commits
account-data: pin openvibe-sdk 0.74.0 and guard every table with a person column (#148)
Changes
@@@ -290,7 +290,7 @@ by editors; signals arrive only from Sources.- OpenVibe.AI — optional, proposes summaries through `reviews.summary.propose`- OpenVibe.Search — consumes the index events- PostgreSQL 18 and Valkey 9 (OpenVibe.Host `roles/data/`, ADR-035): every read and write is async through `openvibe-sdk/db`; Valkey holds the per-actor limit counters (optional)--- packages: openvibe-publishing v1.3.0, openvibe-contracts v0.107.0, openvibe-shared v4.48.0, openvibe-sdk v0.67.0++- packages: openvibe-publishing v1.3.0, openvibe-contracts v0.107.0, openvibe-shared v4.48.0, openvibe-sdk v0.74.0## Capabilities@@@ -385,7 +385,7 @@ Part of the [OpenVibe network](https://openvibe.network). Built in the open by [<!-- versions:start -->- openvibe-contracts: v0.222.0--- openvibe-sdk: v0.67.0++- openvibe-sdk: v0.74.0- openvibe-shared: v4.48.0- openvibe-publishing: v1.3.0<!-- versions:end -->@@@ -8,12 +8,12 @@"port": 4830,"domain": "openvibe.reviews","contracts": "openvibe-contracts v0.222.0",-- "sdk": "openvibe-sdk v0.67.0",++ "sdk": "openvibe-sdk v0.74.0","shared": "openvibe-shared v4.48.0","packages": ["openvibe-publishing v1.3.0","openvibe-shared v4.48.0",-- "openvibe-sdk v0.67.0"++ "openvibe-sdk v0.74.0"],"capabilities": ["reviews.entity.resolve",@@@ -16,7 +16,7 @@"iovalkey": "^0.4.0","openvibe-contracts": "https://codeload.github.com/OpenVibers/OpenVibe.Contracts/tar.gz/refs/tags/v0.222.0","openvibe-publishing": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.3.0",-- "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.67.0",++ "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.74.0","openvibe-shared": "https://codeload.github.com/OpenVibers/OpenVibe.Shared/tar.gz/refs/tags/v4.48.0","pg": "^8.23.0"},@@@ -1168,9 +1168,9 @@}},"node_modules/openvibe-sdk": {-- "version": "0.67.0",-- "resolved": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.67.0",-- "integrity": "sha512-s7NzjaNcowVcOIiup2z0ze+xsq/qnr++3pHSI8JzirqJPQ5JsBSUF5RkjOHyfk9bRKlmhY0fsNS6x4dsYylyqw==",++ "version": "0.74.0",++ "resolved": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.74.0",++ "integrity": "sha512-DO9KVPnUriY/I4lX6ZEJtXaUvRDbJyqnqJxvlpl+zkNGFILpmuBXVJogNOCfK071Qci1gg7C4Iw1Xrseklcajg==","license": "MIT","bin": {"openvibe-download": "bin/openvibe-download.js"@@@ -26,7 +26,7 @@"iovalkey": "^0.4.0","openvibe-contracts": "https://codeload.github.com/OpenVibers/OpenVibe.Contracts/tar.gz/refs/tags/v0.222.0","openvibe-publishing": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.3.0",-- "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.67.0",++ "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.74.0","openvibe-shared": "https://codeload.github.com/OpenVibers/OpenVibe.Shared/tar.gz/refs/tags/v4.48.0","pg": "^8.23.0"},@@@ -7,6 +7,8 @@*/const assert = require('assert');const { signDeliveryHeaders } = require('openvibe-sdk/events');++const { uncovered } = require('openvibe-sdk/account-data');++const { TABLES } = require('../server/reviews/account-data');const { boot, req, suite, userToken, cookieFor, subject, outbox, WEBHOOK_SECRET } = require('./helpers');const t = suite('account-data');@@@ -16,6 +18,16 @@ t('export, then deletion: reviews gone and re-indexed, additions and correctionsconst calls = [];const send = async (path, body) => { calls.push({ path, body }); return { ok: true, status: 201 }; };const h = await boot({ send });++ const missing = await uncovered(h.db, {++ tables: TABLES,++ taskKeyed: ['review_entities', 'review_entity_aliases', 'review_entity_links', 'review_summary_drafts'],++ exempt: {++ account_data_events: 'the ledger of requests itself: which export and deletion Reviews applied',++ review_signals: 'signals are imported from OpenVibe.Sources and attributed to the source, not to a person',++ review_index_revisions: "owner is the search-index document's owner (type/id), not a person; the row holds a revision and hash",++ },++ });++ assert.deepStrictEqual(missing, [], `a table with a person column is neither covered nor exempted: ${missing.join(', ')}`);try {const ana = subject();const ben = subject();
@@ -290,7 +290,7 @@ by editors; signals arrive only from Sources.
@@ -290,7 +290,7 @@ by editors; signals arrive only from Sources.
- OpenVibe.AI — optional, proposes summaries through `reviews.summary.propose`
- OpenVibe.AI — optional, proposes summaries through `reviews.summary.propose`
- OpenVibe.Search — consumes the index events
- OpenVibe.Search — consumes the index events
- PostgreSQL 18 and Valkey 9 (OpenVibe.Host `roles/data/`, ADR-035): every read and write is async through `openvibe-sdk/db`; Valkey holds the per-actor limit counters (optional)
- PostgreSQL 18 and Valkey 9 (OpenVibe.Host `roles/data/`, ADR-035): every read and write is async through `openvibe-sdk/db`; Valkey holds the per-actor limit counters (optional)
-- packages: openvibe-publishing v1.3.0, openvibe-contracts v0.107.0, openvibe-shared v4.48.0, openvibe-sdk v0.67.0
+- packages: openvibe-publishing v1.3.0, openvibe-contracts v0.107.0, openvibe-shared v4.48.0, openvibe-sdk v0.74.0
## Capabilities
## Capabilities
@@ -385,7 +385,7 @@ Part of the [OpenVibe network](https://openvibe.network). Built in the open by [
@@ -385,7 +385,7 @@ Part of the [OpenVibe network](https://openvibe.network). Built in the open by [
<!-- versions:start -->
<!-- versions:start -->
- openvibe-contracts: v0.222.0
- openvibe-contracts: v0.222.0
-- openvibe-sdk: v0.67.0
+- openvibe-sdk: v0.74.0
- openvibe-shared: v4.48.0
- openvibe-shared: v4.48.0
- openvibe-publishing: v1.3.0
- openvibe-publishing: v1.3.0
<!-- versions:end -->
<!-- versions:end -->
@@ -8,12 +8,12 @@
@@ -8,12 +8,12 @@
"port": 4830,
"port": 4830,
"domain": "openvibe.reviews",
"domain": "openvibe.reviews",
"contracts": "openvibe-contracts v0.222.0",
"contracts": "openvibe-contracts v0.222.0",
- "sdk": "openvibe-sdk v0.67.0",
+ "sdk": "openvibe-sdk v0.74.0",
"shared": "openvibe-shared v4.48.0",
"shared": "openvibe-shared v4.48.0",
"packages": [
"packages": [
"openvibe-publishing v1.3.0",
"openvibe-publishing v1.3.0",
"openvibe-shared v4.48.0",
"openvibe-shared v4.48.0",
- "openvibe-sdk v0.67.0"
+ "openvibe-sdk v0.74.0"
],
],
"capabilities": [
"capabilities": [
"reviews.entity.resolve",
"reviews.entity.resolve",
@@ -16,7 +16,7 @@
@@ -16,7 +16,7 @@
"iovalkey": "^0.4.0",
"iovalkey": "^0.4.0",
"openvibe-contracts": "https://codeload.github.com/OpenVibers/OpenVibe.Contracts/tar.gz/refs/tags/v0.222.0",
"openvibe-contracts": "https://codeload.github.com/OpenVibers/OpenVibe.Contracts/tar.gz/refs/tags/v0.222.0",
"openvibe-publishing": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.3.0",
"openvibe-publishing": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.3.0",
- "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.67.0",
+ "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.74.0",
"openvibe-shared": "https://codeload.github.com/OpenVibers/OpenVibe.Shared/tar.gz/refs/tags/v4.48.0",
"openvibe-shared": "https://codeload.github.com/OpenVibers/OpenVibe.Shared/tar.gz/refs/tags/v4.48.0",
"pg": "^8.23.0"
"pg": "^8.23.0"
},
},
@@ -1168,9 +1168,9 @@
@@ -1168,9 +1168,9 @@
}
}
},
},
"node_modules/openvibe-sdk": {
"node_modules/openvibe-sdk": {
- "version": "0.67.0",
- "resolved": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.67.0",
- "integrity": "sha512-s7NzjaNcowVcOIiup2z0ze+xsq/qnr++3pHSI8JzirqJPQ5JsBSUF5RkjOHyfk9bRKlmhY0fsNS6x4dsYylyqw==",
+ "version": "0.74.0",
+ "resolved": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.74.0",
+ "integrity": "sha512-DO9KVPnUriY/I4lX6ZEJtXaUvRDbJyqnqJxvlpl+zkNGFILpmuBXVJogNOCfK071Qci1gg7C4Iw1Xrseklcajg==",
"license": "MIT",
"license": "MIT",
"bin": {
"bin": {
"openvibe-download": "bin/openvibe-download.js"
"openvibe-download": "bin/openvibe-download.js"
@@ -26,7 +26,7 @@
@@ -26,7 +26,7 @@
"iovalkey": "^0.4.0",
"iovalkey": "^0.4.0",
"openvibe-contracts": "https://codeload.github.com/OpenVibers/OpenVibe.Contracts/tar.gz/refs/tags/v0.222.0",
"openvibe-contracts": "https://codeload.github.com/OpenVibers/OpenVibe.Contracts/tar.gz/refs/tags/v0.222.0",
"openvibe-publishing": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.3.0",
"openvibe-publishing": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.3.0",
- "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.67.0",
+ "openvibe-sdk": "https://codeload.github.com/OpenVibers/OpenVibe.SDK/tar.gz/refs/tags/v0.74.0",
"openvibe-shared": "https://codeload.github.com/OpenVibers/OpenVibe.Shared/tar.gz/refs/tags/v4.48.0",
"openvibe-shared": "https://codeload.github.com/OpenVibers/OpenVibe.Shared/tar.gz/refs/tags/v4.48.0",
"pg": "^8.23.0"
"pg": "^8.23.0"
},
},
@@ -7,6 +7,8 @@
@@ -7,6 +7,8 @@
*/
*/
const assert = require('assert');
const assert = require('assert');
const { signDeliveryHeaders } = require('openvibe-sdk/events');
const { signDeliveryHeaders } = require('openvibe-sdk/events');
+const { uncovered } = require('openvibe-sdk/account-data');
+const { TABLES } = require('../server/reviews/account-data');
const { boot, req, suite, userToken, cookieFor, subject, outbox, WEBHOOK_SECRET } = require('./helpers');
const { boot, req, suite, userToken, cookieFor, subject, outbox, WEBHOOK_SECRET } = require('./helpers');
const t = suite('account-data');
const t = suite('account-data');
@@ -16,6 +18,16 @@ t('export, then deletion: reviews gone and re-indexed, additions and corrections
@@ -16,6 +18,16 @@ t('export, then deletion: reviews gone and re-indexed, additions and corrections
const calls = [];
const calls = [];
const send = async (path, body) => { calls.push({ path, body }); return { ok: true, status: 201 }; };
const send = async (path, body) => { calls.push({ path, body }); return { ok: true, status: 201 }; };
const h = await boot({ send });
const h = await boot({ send });
+ const missing = await uncovered(h.db, {
+ tables: TABLES,
+ taskKeyed: ['review_entities', 'review_entity_aliases', 'review_entity_links', 'review_summary_drafts'],
+ exempt: {
+ account_data_events: 'the ledger of requests itself: which export and deletion Reviews applied',
+ review_signals: 'signals are imported from OpenVibe.Sources and attributed to the source, not to a person',
+ review_index_revisions: "owner is the search-index document's owner (type/id), not a person; the row holds a revision and hash",
+ },
+ });
+ assert.deepStrictEqual(missing, [], `a table with a person column is neither covered nor exempted: ${missing.join(', ')}`);
try {
try {
const ana = subject();
const ana = subject();
const ben = subject();
const ben = subject();