openvibers/openvibe.news Commits
Restore the openvibe-publishing sha512 integrity in the lockfile
Changes
@@@ -3,3 +3,4 @@## Unreleased- Every page is rendered through `openvibe-publishing/layout` (v1.2.0, on `openvibe-shared/shell` v2.6.0): the head, the Frame, the noscript navigation, the footer and its init come from the shared document; robots and the canonical still come from the indexability gate's decision. The shell adds `web-runtime.js`, so the home page's JS budget is raised to 5 files, 245 KB, 59 KB brotli.++- The `openvibe-publishing` v1.2.0 lock entry carries its sha512 integrity again (the bump had dropped it), and a test fails if any codeload pin loses its hash.@@@ -1165,6 +1165,7 @@"node_modules/openvibe-publishing": {"version": "1.2.0","resolved": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.2.0",++ "integrity": "sha512-n/20yxXo5jRs0wi7KsR+R9jDkGsoBak3gqElHV6XyU+i1t3XCzaoz+sDb10G2cbc4uEaNB/F09VtQKrQzLp6YQ==","license": "MIT","engines": {"node": ">=20"nnew file mode 100644@@@ -0,0 +1,25 @@++'use strict';++/**++ * Every dependency pinned to a GitHub tag carries the sha512 its tarball hashes to. A hand-edited++ * bump of a codeload pin can silently drop that line (the Reviews layout PR did), so the entry is++ * checked here instead of being noticed only when a sibling copies the missing hash.++ */++const assert = require('assert');++const fs = require('fs');++const path = require('path');++const { check, done } = require('./helpers/boot');++++const ROOT = path.join(__dirname, '..');++++(async () => {++ await check('every codeload dependency in package-lock.json pins a sha512 integrity', () => {++ const lock = JSON.parse(fs.readFileSync(path.join(ROOT, 'package-lock.json'), 'utf8'));++ const missing = Object.entries(lock.packages || {})++ .filter(([, p]) => typeof p.resolved === 'string' && p.resolved.startsWith('https://codeload.github.com/'))++ .filter(([, p]) => !p.integrity)++ .map(([name, p]) => `${name}@${p.version || '?'}`);++ assert.deepStrictEqual(missing, [], `lock entries without integrity: ${missing.join(', ')}`);++ });++++ done();++})();
@@ -3,3 +3,4 @@
@@ -3,3 +3,4 @@
## Unreleased
## Unreleased
- Every page is rendered through `openvibe-publishing/layout` (v1.2.0, on `openvibe-shared/shell` v2.6.0): the head, the Frame, the noscript navigation, the footer and its init come from the shared document; robots and the canonical still come from the indexability gate's decision. The shell adds `web-runtime.js`, so the home page's JS budget is raised to 5 files, 245 KB, 59 KB brotli.
- Every page is rendered through `openvibe-publishing/layout` (v1.2.0, on `openvibe-shared/shell` v2.6.0): the head, the Frame, the noscript navigation, the footer and its init come from the shared document; robots and the canonical still come from the indexability gate's decision. The shell adds `web-runtime.js`, so the home page's JS budget is raised to 5 files, 245 KB, 59 KB brotli.
+- The `openvibe-publishing` v1.2.0 lock entry carries its sha512 integrity again (the bump had dropped it), and a test fails if any codeload pin loses its hash.
@@ -1165,6 +1165,7 @@
@@ -1165,6 +1165,7 @@
"node_modules/openvibe-publishing": {
"node_modules/openvibe-publishing": {
"version": "1.2.0",
"version": "1.2.0",
"resolved": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.2.0",
"resolved": "https://codeload.github.com/OpenVibers/OpenVibe.Publishing/tar.gz/refs/tags/v1.2.0",
+ "integrity": "sha512-n/20yxXo5jRs0wi7KsR+R9jDkGsoBak3gqElHV6XyU+i1t3XCzaoz+sDb10G2cbc4uEaNB/F09VtQKrQzLp6YQ==",
"license": "MIT",
"license": "MIT",
"engines": {
"engines": {
"node": ">=20"
"node": ">=20"
new file mode 100644
new file mode 100644
@@ -0,0 +1,25 @@
@@ -0,0 +1,25 @@
+'use strict';
+/**
+ * Every dependency pinned to a GitHub tag carries the sha512 its tarball hashes to. A hand-edited
+ * bump of a codeload pin can silently drop that line (the Reviews layout PR did), so the entry is
+ * checked here instead of being noticed only when a sibling copies the missing hash.
+ */
+const assert = require('assert');
+const fs = require('fs');
+const path = require('path');
+const { check, done } = require('./helpers/boot');
+
+const ROOT = path.join(__dirname, '..');
+
+(async () => {
+ await check('every codeload dependency in package-lock.json pins a sha512 integrity', () => {
+ const lock = JSON.parse(fs.readFileSync(path.join(ROOT, 'package-lock.json'), 'utf8'));
+ const missing = Object.entries(lock.packages || {})
+ .filter(([, p]) => typeof p.resolved === 'string' && p.resolved.startsWith('https://codeload.github.com/'))
+ .filter(([, p]) => !p.integrity)
+ .map(([name, p]) => `${name}@${p.version || '?'}`);
+ assert.deepStrictEqual(missing, [], `lock entries without integrity: ${missing.join(', ')}`);
+ });
+
+ done();
+})();