GLOBALGRID2050 / EXPLORE CODE

Part of: Explore Code / Electricity markets and data pipelines / globalgrid2050 / uk_renewables_pipeline/v9.5.1/tests

Check V9 5 1 and 4 more files (part 1)

A JavaScript module in the tests folder of GlobalGrid2050 that tests major project news, homepage catalogue and the Renewable Energy Planning Database (REPD) register, using SHA-256.

690 lines of JavaScript and Shell from globalgrid2050, in 5 files. Topic: Electricity markets and data pipelines. Section 969 of 2044.

Cut 2026-12-06T03:07:51+00:00. A copy for reading; the repository at the stated commit is the source.

In the State lines below, domain stage, users and canonical status are rule-based first approximations from code and path evidence (rules explore-agent-rules-v1), not observed facts: the rules.

In this section

  1. Check V9 4 test · globalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/check_v9_4.mjs lines 1–187
  2. Check V9 5 test · globalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/check_v9_5.mjs lines 1–193
  3. Check V9 5 1 test · globalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/check_v9_5_1.mjs lines 1–229
  4. Run V9 5 test · globalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/run_v9_5.sh lines 1–38
  5. Run V9 5 1 test · globalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/run_v9_5_1.sh lines 1–43

Check V9 4

A JavaScript module in the tests folder of GlobalGrid2050 that tests major project news and the Renewable Energy Planning Database (REPD) register, using SHA-256.

Set aside from the main view: 99% of its lines are the same as uk_renewables_pipeline/202609051156/tests/check_v9_4.mjs (globalgrid2050), which stays. (near-copy-of, proposed by families.py). 98% of lines shared with Check V9 4; read that one first. All set-aside files, with reasons. Nothing was deleted.

Evidence
  • line-jaccard 0.988 to globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/202609051156/tests/check_v9_4.mjs:1-187 8d5d02b2df4856dc492db93f0d7ef2d3ea4999ca
  • sha256 7302057c4fbc139c0ed8ef42075daf355b0b059479a68ffff4b8eef1b2e0cb2a
  • target sha256 c97445b3901d4ba921690c3db6eb2be14007c0c427b710e44ec1a224872379a6
  • group of 3 (identity.json near-copy edges >= 0.9)
  • canonical rule: reachable, newest stamp, core repo, most lines

testglobalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/check_v9_4.mjs · lines 1–187 of 187 · Not reached from any entry point (candidate for review) · pattern gitTree (shared by 16 files)

What it does
It tests major project news and the REPD register. Defines readText, readJson, sha256, gitBlob, gitTree. Uses libraries node:assert/strict, node:child_process, node:crypto, node:fs/promises, node:url. Side effects: changes the web page (DOM); reads or writes files; starts processes.
Why it exists in the grid workflow
Domain stage upstream_foresight (path word 'renewables'): upstream engineering foresight over GB transmission and distribution topology (TSO/DNO, 132kV and above, the REPD pipeline, data centres), which Ventus Ltd states it models for foresight. Domain terms in the code: the REPD register.
Inputs & outputs
In: JSON file release.v9.4.json; JSON file release.v9.3.json; JSON file release.v9.1.json; JSON file v9_manifest.json; JSON file build_manifest.json; JSON file major_project_news_v5.json.
What it achieves
It reads text (`readText`) and reads JSON (`readJson`). Defines `readText`, `readJson`, `sha256` and 2 more. It reads `contracts/release.v9.4.json`.
Why it matters
No other file in the estate was found to import it.
Application
globalgrid2050 · uk_renewables_pipeline/v9.5.1/tests · JavaScript module
Uses
Project Filter V9 2 (import), News Relevance V9 2 (import), Projects V9 4 (import), UK Renewables Pipeline — V9 5 1 Page (new URL import.meta.url), node:assert/strict, node:child_process, node:crypto, node:fs/promises, node:url
Used by
none found
Produces
readText, readJson, sha256, gitBlob, gitTree
Defines here
readText, readJson, sha256, gitBlob, gitTree
Cannot conclude
Whether this code runs, is used by a live app today, or is correct. This is a static reading.
Evidence
globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/v9.5.1/tests/check_v9_4.mjs:1-187 · blob 0d2230a609f13ecb73398cdf93b1cd03a23d1a04 · GitHub at these lines
State
achieves: name · context: readme_derived · stage: output · effects: dom, filesystem, process · domain stage: upstream_foresight · users: IPP_developer, ICP_grid_engineer · canonical: unreached_review
import assert from "node:assert/strict";
import { execFileSync } from "node:child_process";
import { createHash } from "node:crypto";
import { readFile } from "node:fs/promises";
import { fileURLToPath } from "node:url";
import {
  buildProjectSearchTextV9_2,
  projectMatchesV9_2,
  summariseProjectsV9_2,
  tokeniseSearchV9_2,
} from "../scripts/core/project-filter-v9-2.js";
import { assessNewsItemV9_2 } from "../scripts/core/news-relevance-v9-2.js";
import { atlasUrlV9_4, compareProjectUpdatesV9_4 } from "../scripts/plugins/projects-v9-4.js";

const base = new URL("../", import.meta.url);
const root = new URL("../../../", import.meta.url);
const rootPath = fileURLToPath(root);
const readText = (path) => readFile(new URL(path, base), "utf8");
const readJson = async (path) => JSON.parse(await readText(path));
const sha256 = (value) => createHash("sha256").update(value).digest("hex");
const gitBlob = (path) => execFileSync("git", ["-C", rootPath, "hash-object", path], { encoding: "utf8" }).trim();
const gitTree = (revisionPath) => execFileSync("git", ["-C", rootPath, "rev-parse", revisionPath], { encoding: "utf8" }).trim();

const contract = await readJson("contracts/release.v9.4.json");
const parentContract = await readJson("contracts/release.v9.3.json");
const dataContract = await readJson("contracts/release.v9.1.json");
const releaseManifest = await readJson("data/v9_manifest.json");
const payload = await readJson("data/v9.1/build_manifest.json");
const projectParts = await Promise.all(payload.project_partitions.map(({ path }) => readJson(path)));
const projects = projectParts.flatMap((part) => part.projects);
const news = JSON.parse(await readFile(new URL("dist/major_project_news_v5.json", root), "utf8"));

assert.equal(contract.release, "9.4");
assert.equal(contract.frozen_parent.release, "9.3.1");
assert.equal(contract.frozen_parent.commit, "9e0c51281fc816691a75e4255483a0851122481e");
assert.equal(contract.frozen_parent.subtree, "a32ffa54543f090eb08211941b50b049580c3c55");
assert.equal(contract.frozen_parent.tree_listing_sha256, "fe3d611555c7d9f19c64fa30105dfecb4ba68e649cd55d6424219b7081d07951");
assert.equal(contract.frozen_parent.must_remain_unchanged, true);
assert.equal(gitTree("HEAD:uk_renewables_pipeline/v9"), contract.frozen_parent.subtree, "V9.3.1 subtree changed while building V9.4");
assert.equal(contract.data_parent.release, "9.1");
assert.equal(contract.data_parent.data_changed, false);
assert.equal(parentContract.release, "9.3");
assert.equal(dataContract.release, "9.1");
assert.equal(releaseManifest.version, "9.4");
assert.ok(["CANDIDATE", "LIVE_VALIDATED"].includes(releaseManifest.status));
assert.equal(releaseManifest.frozen_v9_3_1_commit, contract.frozen_parent.commit);
assert.equal(releaseManifest.frozen_v9_3_1_subtree, contract.frozen_parent.subtree);
assert.equal(contract.ui_contract.first_click, "updated_desc");
assert.equal(contract.ui_contract.second_click, "updated_asc");
assert.equal(contract.ui_contract.aria_sort_default, "none");
assert.equal(contract.ui_contract.aria_sort_newest, "descending");
assert.equal(contract.ui_contract.aria_sort_oldest, "ascending");
assert.equal(contract.ui_contract.project_table_columns, 11);

const frozenV92Blobs = {
  "uk_renewables_pipeline/v9/scripts/core/project-filter-v9-2.js": "dceee01d0f51e85b071aef275250c1fb223eeba7",
  "uk_renewables_pipeline/v9/scripts/core/news-relevance-v9-2.js": "f8374bfd6f0c47e98ca1e7f2f3312c9281a34e8a",
  "uk_renewables_pipeline/v9/scripts/data/canonical-projects-v9-2.js": "e3d9b7bb0f39b813cf3b1f125467efbd6a021dda",
  "uk_renewables_pipeline/v9/scripts/plugins/gauges-v9-2.js": "1d081d2d9e1630912b912953cf18f431754f9e19",
  "uk_renewables_pipeline/v9/scripts/plugins/newspaper-v9-2.js": "6c72de9e9bd8f41bf525a32ca2436e53ddb466b0",
  "uk_renewables_pipeline/v9/scripts/plugins/projects-v9-2.js": "0e222ea75e9db8dc3e9f1e829a15ac3ee1ca0acf",
  "uk_renewables_pipeline/v9/styles/v9-2.css": "f4ac1a09145b0f4824e333ac2acbc767d84f2da6",
};
for (const [path, expected] of Object.entries(frozenV92Blobs)) {
  assert.equal(gitBlob(path), expected, `${path} changed after the frozen V9.2 checkpoint`);
}

assert.equal(payload.project_count, 7680);
assert.equal(payload.capacity_mw, 356474.09);
assert.equal(payload.largest_mw, 4100);
assert.equal(payload.geometry_count, 7652);
assert.equal(payload.missing_geometry_count, 28);
assert.equal(payload.solar_count, 3563);
assert.equal(payload.bess_count, 1609);
assert.equal(payload.wind_onshore_count, 2399);
assert.equal(payload.wind_offshore_count, 109);
assert.equal(projects.length, 7680);
assert.equal(new Set(projects.map((project) => project.repd_ref)).size, 7680);
assert.ok(projects.every((project) => project.capacity_mw >= 1));
assert.deepEqual(summariseProjectsV9_2(projects), { count: 7680, capacity_mw: 356474.09, largest_mw: 4100 });

const datedProjects = projects.filter((project) => project.repd_record_updated);
const undatedProjects = projects.filter((project) => !project.repd_record_updated);
assert.ok(datedProjects.length > 1);
assert.ok(datedProjects.every((project) => /^\d{4}-\d{2}-\d{2}$/.test(project.repd_record_updated)));
const newestFirst = [...projects].sort((left, right) => compareProjectUpdatesV9_4(left, right, "desc"));
const oldestFirst = [...projects].sort((left, right) => compareProjectUpdatesV9_4(left, right, "asc"));
assert.ok(newestFirst[0].repd_record_updated >= newestFirst[1].repd_record_updated);
assert.ok(oldestFirst[0].repd_record_updated <= oldestFirst[1].repd_record_updated);
if (undatedProjects.length) {
  assert.equal(newestFirst.at(-1).repd_record_updated, null);
  assert.equal(oldestFirst.at(-1).repd_record_updated, null);
}

const berwick = projects.find((project) => project.repd_ref === "9873");
assert.ok(berwick);
const searchText = buildProjectSearchTextV9_2(berwick);
assert.equal(projectMatchesV9_2(berwick, {
  technology: "wind_offshore",
  status: "All",
  county: "All",
  tokens: tokeniseSearchV9_2("GG2050-REPD-9873 Berwick"),
}, searchText), true);
assert.equal(projectMatchesV9_2(berwick, {
  technology: "solar",
  status: "All",
  county: "All",
  tokens: [],
}, searchText), false);

const validAtlas = new URL(atlasUrlV9_4(berwick));
assert.equal(validAtlas.searchParams.get("repd_ref"), "9873");
assert.equal(validAtlas.searchParams.get("technology"), "wind_offshore");
const missingGeometry = projects.find((project) => project.geometry_status !== "valid");
assert.ok(missingGeometry);
assert.equal(atlasUrlV9_4(missingGeometry), "");

const beacon = news.items.find((item) => /Beacon Fen Energy Park development consent decision announced/i.test(item.headline));
const grange = news.items.find((item) => /The Grange celebrates Forest Healthcare/i.test(item.headline));
const wilton = news.items.find((item) => /New Jersey Board of Public Utilities/i.test(item.headline));
const stonestreet = news.items.find((item) => /Evolution Mining/i.test(item.headline));
assert.ok(beacon && grange && wilton && stonestreet);
assert.equal(assessNewsItemV9_2(beacon).strong, true);
assert.equal(assessNewsItemV9_2(grange).strong, false);
assert.equal(assessNewsItemV9_2(wilton).strong, false);
assert.equal(assessNewsItemV9_2(stonestreet).strong, false);

const html = await readText("index.html");
const mobileCss = await readText("styles/mobile.css");
const additiveCss = await readText("styles/v9-3.css");
const parentAdditiveCss = await readText("styles/v9-2.css");
const headerCss = await readText("styles/v9-4.css");
const frozenParentCss = await readFile(new URL("uk_renewables_pipeline/v9/styles/v9-3.css", root), "utf8");
const projectsV94 = await readText("scripts/plugins/projects-v9-4.js");
const app = await readText("scripts/app-v9-4.js");
const rootIndex = await readFile(new URL("index.html", root), "utf8");
const packageJson = await readJson("package.json");

assert.match(html, /UK RENEWABLES PIPELINE V9\.4/);
assert.match(html, />V9\.4 (?:CANDIDATE|LIVE)</);
assert.match(html, /V9\.3\.1 FROZEN APP/);
const styleOrder = [
  html.indexOf("styles/v7.css?v=9.4"),
  html.indexOf("styles/mobile.css?v=9.4"),
  html.indexOf("styles/v9-3.css?v=9.4"),
  html.indexOf("styles/v9-4.css?v=9.4"),
];
assert.ok(styleOrder.every((value) => value >= 0));
assert.ok(styleOrder.every((value, index) => index === 0 || value > styleOrder[index - 1]));
assert.equal((html.match(/<canvas id="g[1-3]"/g) || []).length, 3);
assert.equal((html.match(/<th(?:\s|>)/g) || []).length, 11);
assert.match(html, /<th class="hide-mobile">REPD REF<\/th>/);
assert.match(html, /<th class="hide-mobile">GLOBALGRID REF<\/th>/);
assert.match(html, /id="repdUpdatedHeader" aria-sort="none"/);
assert.match(html, /id="sortUpdated"/);
assert.match(html, /id="updatedSortIndicator"[^>]*>↕<\/span>/);
assert.match(html, /id="sortProjects"/);
assert.match(html, /value="updated_desc"/);
assert.match(html, /value="updated_asc"/);
assert.match(html, /scripts\/app-v9-4\.js\?v=9\.4/);

assert.equal(sha256(mobileCss), "9855b9c11255a85f477873d07cca45b057aedcdc8a6cc4aab2d29a0ffaac9b85");
assert.equal(additiveCss, frozenParentCss, "V9.4 changed its inherited V9.3.1 stylesheet copy");
const parentCssPrefix = parentAdditiveCss.trimEnd();
assert.ok(additiveCss.startsWith(parentCssPrefix), "V9.3 additive CSS no longer preserves the complete V9.2 prefix");
assert.match(headerCss, /\.repd-updated-heading button/);
assert.match(headerCss, /#updatedSortIndicator/);
assert.match(headerCss, /focus-visible/);

assert.match(app, /gauges-v9-2\.js/);
assert.match(app, /newspaper-v9-2\.js/);
assert.match(app, /projects-v9-4\.js/);
assert.match(projectsV94, /globalgrid2050_uk_renewables_pipeline_v9_4_/);
assert.match(projectsV94, /compareProjectUpdatesV9_4/);
assert.match(projectsV94, /function updateSortHeader\(\)/);
assert.match(projectsV94, /sortMode === "updated_desc" \? "updated_asc" : "updated_desc"/);
assert.match(projectsV94, /document\.getElementById\("sortUpdated"\)\.onclick/);
assert.match(projectsV94, /header\.setAttribute\("aria-sort", "descending"\)/);
assert.match(projectsV94, /header\.setAttribute\("aria-sort", "ascending"\)/);

assert.match(rootIndex, /UK Renewables Pipeline V9\.3\.1/);
assert.match(rootIndex, /UK Renewables Pipeline V9\.4/);
assert.equal(packageJson.version, "9.4.0");
assert.equal(packageJson.scripts.validate, "bash tests/run_v9_4.sh");
assert.equal(packageJson.scripts["validate:browser"], "V9_BROWSER_SMOKE=1 bash tests/run_v9_4.sh");

console.log("V9.4: PASS (clickable REPD UPDATED header; V9.3.1 subtree frozen; 7,680-record data retained)");

Check V9 5

A JavaScript module in the tests folder of GlobalGrid2050 that tests major project news and the Renewable Energy Planning Database (REPD) register, using SHA-256.

Set aside from the main view: 99% of its lines are the same as uk_renewables_pipeline/202609051156/tests/check_v9_5.mjs (globalgrid2050), which stays. (near-copy-of, proposed by families.py). 98% of lines shared with Check V9 5; read that one first. All set-aside files, with reasons. Nothing was deleted.

Evidence
  • line-jaccard 0.9884 to globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/202609051156/tests/check_v9_5.mjs:1-193 1be56af8f27fe40aefae5d8595b9d5286460ce18
  • sha256 c88bef8cda6bf83b020a3d82079bfd13bdad17aa0f921ec9bdc39cd61b10590b
  • target sha256 c2c83d780dbce3f50a2a2020dfbd8f9ada5d0d2dbcd974a802577410ca10deb9
  • group of 3 (identity.json near-copy edges >= 0.9)
  • canonical rule: reachable, newest stamp, core repo, most lines

testglobalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/check_v9_5.mjs · lines 1–193 of 193 · pattern gitTree (shared by 16 files)

What it does
It tests major project news and the REPD register. Defines readText, readJson, sha256, gitBlob, gitTree. Uses libraries node:assert/strict, node:child_process, node:crypto, node:fs/promises, node:url. Side effects: changes the web page (DOM); reads or writes files; starts processes.
Why it exists in the grid workflow
Domain stage upstream_foresight (path word 'renewables'): upstream engineering foresight over GB transmission and distribution topology (TSO/DNO, 132kV and above, the REPD pipeline, data centres), which Ventus Ltd states it models for foresight. Domain terms in the code: the REPD register.
Inputs & outputs
In: JSON file release.v9.5.json; JSON file release.v9.4.json; JSON file release.v9.1.json; JSON file v9_manifest.json; JSON file build_manifest.json; JSON file major_project_news_v6.json.
Downstream impact
Used directly by 1 file: Run V9 5 (globalgrid2050).
What it achieves
It reads text (`readText`) and reads JSON (`readJson`). Defines `readText`, `readJson`, `sha256` and 2 more. It reads `contracts/release.v9.5.json`.
Why it matters
Checked by Run V9 5.
Application
globalgrid2050 · uk_renewables_pipeline/v9.5.1/tests · JavaScript module
Uses
Projects V9 5 (script call), Project Filter V9 2 (import), UK Renewables Pipeline — V9 5 1 Page (new URL import.meta.url), node:assert/strict, node:child_process, node:crypto, node:fs/promises, node:url
Used by
run by Run V9 5 (script call)
Produces
readText, readJson, sha256, gitBlob, gitTree
Defines here
readText, readJson, sha256, gitBlob, gitTree
Cannot conclude
Whether this code runs, is used by a live app today, or is correct. This is a static reading.
Evidence
globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/v9.5.1/tests/check_v9_5.mjs:1-193 · blob 674608d064a5edb8dd243614da7bdd8216d50027 · GitHub at these lines
State
achieves: name · context: readme_derived · stage: output · effects: dom, filesystem, process · domain stage: upstream_foresight · users: IPP_developer, ICP_grid_engineer · canonical: production_core
import assert from "node:assert/strict";
import { execFileSync } from "node:child_process";
import { createHash } from "node:crypto";
import { readFile } from "node:fs/promises";
import { fileURLToPath } from "node:url";
import {
  buildProjectSearchTextV9_2,
  projectMatchesV9_2,
  summariseProjectsV9_2,
  tokeniseSearchV9_2,
} from "../scripts/core/project-filter-v9-2.js";
import { atlasUrlV9_5, compareProjectUpdatesV9_5 } from "../scripts/plugins/projects-v9-5.js";

const base = new URL("../", import.meta.url);
const root = new URL("../../../", import.meta.url);
const rootPath = fileURLToPath(root);
const readText = (path) => readFile(new URL(path, base), "utf8");
const readJson = async (path) => JSON.parse(await readText(path));
const sha256 = (value) => createHash("sha256").update(value).digest("hex");
const gitBlob = (path) => execFileSync("git", ["-C", rootPath, "hash-object", path], { encoding: "utf8" }).trim();
const gitTree = (revisionPath) => execFileSync("git", ["-C", rootPath, "rev-parse", revisionPath], { encoding: "utf8" }).trim();

const contract = await readJson("contracts/release.v9.5.json");
const parentContract = await readJson("contracts/release.v9.4.json");
const dataContract = await readJson("contracts/release.v9.1.json");
const releaseManifest = await readJson("data/v9_manifest.json");
const payload = await readJson("data/v9.1/build_manifest.json");
const projectParts = await Promise.all(payload.project_partitions.map(({ path }) => readJson(path)));
const projects = projectParts.flatMap((part) => part.projects);
const news = JSON.parse(await readFile(new URL("dist/major_project_news_v6.json", root), "utf8"));

assert.equal(contract.release, "9.5");
assert.equal(contract.frozen_parent.release, "9.4");
assert.equal(contract.frozen_parent.commit, "d598d9b6b89be4daeb904fafae52dd18ba35d1c1");
assert.equal(contract.frozen_parent.subtree, "ae91e24c0f6e997ef4d9bd23dd70ea9779ea68b3");
assert.equal(contract.frozen_parent.tree_listing_sha256, "72ab62c1129f0501e78c89ebff8ba8c0967197738916e556a7f6553699f69e8c");
assert.equal(contract.frozen_parent.must_remain_unchanged, true);
assert.equal(gitTree("HEAD:uk_renewables_pipeline/v9.4"), contract.frozen_parent.subtree, "V9.4 subtree changed while building V9.5");
assert.equal(contract.data_parent.release, "9.1");
assert.equal(contract.data_parent.data_changed, false);
assert.equal(parentContract.release, "9.4");
assert.equal(dataContract.release, "9.1");
assert.equal(releaseManifest.version, "9.5");
assert.ok(["CANDIDATE", "LIVE_VALIDATED"].includes(releaseManifest.status));
assert.equal(releaseManifest.frozen_v9_4_commit, contract.frozen_parent.commit);
assert.equal(releaseManifest.frozen_v9_4_subtree, contract.frozen_parent.subtree);
assert.equal(contract.ui_contract.first_click, "updated_desc");
assert.equal(contract.ui_contract.second_click, "updated_asc");
assert.equal(contract.ui_contract.aria_sort_default, "none");
assert.equal(contract.ui_contract.aria_sort_newest, "descending");
assert.equal(contract.ui_contract.aria_sort_oldest, "ascending");
assert.equal(contract.ui_contract.project_table_columns, 11);

const frozenV92Blobs = {
  "uk_renewables_pipeline/v9/scripts/core/project-filter-v9-2.js": "dceee01d0f51e85b071aef275250c1fb223eeba7",
  "uk_renewables_pipeline/v9/scripts/core/news-relevance-v9-2.js": "f8374bfd6f0c47e98ca1e7f2f3312c9281a34e8a",
  "uk_renewables_pipeline/v9/scripts/data/canonical-projects-v9-2.js": "e3d9b7bb0f39b813cf3b1f125467efbd6a021dda",
  "uk_renewables_pipeline/v9/scripts/plugins/gauges-v9-2.js": "1d081d2d9e1630912b912953cf18f431754f9e19",
  "uk_renewables_pipeline/v9/scripts/plugins/newspaper-v9-2.js": "6c72de9e9bd8f41bf525a32ca2436e53ddb466b0",
  "uk_renewables_pipeline/v9/scripts/plugins/projects-v9-2.js": "0e222ea75e9db8dc3e9f1e829a15ac3ee1ca0acf",
  "uk_renewables_pipeline/v9/styles/v9-2.css": "f4ac1a09145b0f4824e333ac2acbc767d84f2da6",
};
for (const [path, expected] of Object.entries(frozenV92Blobs)) {
  assert.equal(gitBlob(path), expected, `${path} changed after the frozen V9.2 checkpoint`);
}

assert.equal(payload.project_count, 7680);
assert.equal(payload.capacity_mw, 356474.09);
assert.equal(payload.largest_mw, 4100);
assert.equal(payload.geometry_count, 7652);
assert.equal(payload.missing_geometry_count, 28);
assert.equal(payload.solar_count, 3563);
assert.equal(payload.bess_count, 1609);
assert.equal(payload.wind_onshore_count, 2399);
assert.equal(payload.wind_offshore_count, 109);
assert.equal(projects.length, 7680);
assert.equal(new Set(projects.map((project) => project.repd_ref)).size, 7680);
assert.ok(projects.every((project) => project.capacity_mw >= 1));
assert.deepEqual(summariseProjectsV9_2(projects), { count: 7680, capacity_mw: 356474.09, largest_mw: 4100 });

const datedProjects = projects.filter((project) => project.repd_record_updated);
const undatedProjects = projects.filter((project) => !project.repd_record_updated);
assert.ok(datedProjects.length > 1);
assert.ok(datedProjects.every((project) => /^\d{4}-\d{2}-\d{2}$/.test(project.repd_record_updated)));
const newestFirst = [...projects].sort((left, right) => compareProjectUpdatesV9_5(left, right, "desc"));
const oldestFirst = [...projects].sort((left, right) => compareProjectUpdatesV9_5(left, right, "asc"));
assert.ok(newestFirst[0].repd_record_updated >= newestFirst[1].repd_record_updated);
assert.ok(oldestFirst[0].repd_record_updated <= oldestFirst[1].repd_record_updated);
if (undatedProjects.length) {
  assert.equal(newestFirst.at(-1).repd_record_updated, null);
  assert.equal(oldestFirst.at(-1).repd_record_updated, null);
}

const berwick = projects.find((project) => project.repd_ref === "9873");
assert.ok(berwick);
const searchText = buildProjectSearchTextV9_2(berwick);
assert.equal(projectMatchesV9_2(berwick, {
  technology: "wind_offshore",
  status: "All",
  county: "All",
  tokens: tokeniseSearchV9_2("GG2050-REPD-9873 Berwick"),
}, searchText), true);
assert.equal(projectMatchesV9_2(berwick, {
  technology: "solar",
  status: "All",
  county: "All",
  tokens: [],
}, searchText), false);

const validAtlas = new URL(atlasUrlV9_5(berwick));
assert.equal(validAtlas.searchParams.get("repd_ref"), "9873");
assert.equal(validAtlas.searchParams.get("technology"), "wind_offshore");
const missingGeometry = projects.find((project) => project.geometry_status !== "valid");
assert.ok(missingGeometry);
assert.equal(atlasUrlV9_5(missingGeometry), "");

assert.equal(news.schema, "globalgrid2050.major-project-news.v6");
assert.equal(news.headline_count, news.items.length);
assert.ok(news.items.length > 0);
assert.ok(news.items.every((item) => item.role === "PRIMARY_MATCH"));
assert.ok(news.items.every((item) => item.eligible_for_news_signal === true));
assert.ok(news.items.every((item) => String(item.repd_ref)));
assert.ok(news.items.every((item) => item.gg_project_id === `GG2050-REPD-${item.repd_ref}`));
const brecks = news.items.filter((item) => item.repd_ref === "10087");
assert.ok(brecks.length > 0);
assert.ok(brecks.every((item) => item.gg_development_id));

const html = await readText("index.html");
const mobileCss = await readText("styles/mobile.css");
const additiveCss = await readText("styles/v9-3.css");
const parentAdditiveCss = await readText("styles/v9-2.css");
const headerCss = await readText("styles/v9-4.css");
const frozenParentCss = await readFile(new URL("uk_renewables_pipeline/v9/styles/v9-3.css", root), "utf8");
const projectsV95 = await readText("scripts/plugins/projects-v9-5.js");
const newspaperV95 = await readText("scripts/plugins/newspaper-v9-5.js");
const app = await readText("scripts/app-v9-5.js");
const rootIndex = await readFile(new URL("index.html", root), "utf8");
const packageJson = await readJson("package.json");

assert.match(html, /UK RENEWABLES PIPELINE V9\.5/);
assert.match(html, />V9\.5 (?:CANDIDATE|LIVE)</);
assert.match(html, /V9\.4 FROZEN APP/);
const styleOrder = [
  html.indexOf("styles/v7.css?v=9.5"),
  html.indexOf("styles/mobile.css?v=9.5"),
  html.indexOf("styles/v9-3.css?v=9.5"),
  html.indexOf("styles/v9-4.css?v=9.5"),
];
assert.ok(styleOrder.every((value) => value >= 0));
assert.ok(styleOrder.every((value, index) => index === 0 || value > styleOrder[index - 1]));
assert.equal((html.match(/<canvas id="g[1-3]"/g) || []).length, 3);
assert.equal((html.match(/<th(?:\s|>)/g) || []).length, 11);
assert.match(html, /<th class="hide-mobile">REPD REF<\/th>/);
assert.match(html, /<th class="hide-mobile">GLOBALGRID REF<\/th>/);
assert.match(html, /id="repdUpdatedHeader" aria-sort="none"/);
assert.match(html, /id="sortUpdated"/);
assert.match(html, /id="updatedSortIndicator"[^>]*>↕<\/span>/);
assert.match(html, /id="sortProjects"/);
assert.match(html, /value="updated_desc"/);
assert.match(html, /value="updated_asc"/);
assert.match(html, /scripts\/app-v9-5\.js\?v=9\.5/);

assert.equal(sha256(mobileCss), "9855b9c11255a85f477873d07cca45b057aedcdc8a6cc4aab2d29a0ffaac9b85");
assert.equal(additiveCss, frozenParentCss, "V9.4 changed its inherited V9.3.1 stylesheet copy");
const parentCssPrefix = parentAdditiveCss.trimEnd();
assert.ok(additiveCss.startsWith(parentCssPrefix), "V9.3 additive CSS no longer preserves the complete V9.2 prefix");
assert.match(headerCss, /\.repd-updated-heading button/);
assert.match(headerCss, /#updatedSortIndicator/);
assert.match(headerCss, /focus-visible/);

assert.match(app, /gauges-v9-2\.js/);
assert.match(app, /projects-v9-5\.js/);
assert.match(app, /newspaper-v9-5\.js/);
assert.match(projectsV95, /globalgrid2050_uk_renewables_pipeline_v9_5_/);
assert.match(projectsV95, /compareProjectUpdatesV9_5/);
assert.match(projectsV95, /function updateSortHeader\(\)/);
assert.match(projectsV95, /sortMode === "updated_desc" \? "updated_asc" : "updated_desc"/);
assert.match(projectsV95, /document\.getElementById\("sortUpdated"\)\.onclick/);
assert.match(projectsV95, /header\.setAttribute\("aria-sort", "descending"\)/);
assert.match(projectsV95, /header\.setAttribute\("aria-sort", "ascending"\)/);
assert.match(newspaperV95, /item\.role === "PRIMARY_MATCH"/);
assert.match(newspaperV95, /newsIndex\.get\(String\(project\.repd_ref\)\)/);
assert.match(newspaperV95, /major_project_news_v6\.json/);
assert.doesNotMatch(newspaperV95, /normaliseProject\(project\.name\)/);

assert.match(rootIndex, /UK Renewables Pipeline V9\.3\.1/);
assert.match(rootIndex, /UK Renewables Pipeline V9\.4/);
assert.match(rootIndex, /UK Renewables Pipeline V9\.5/);
assert.equal(packageJson.version, "9.5.0");
assert.equal(packageJson.scripts.validate, "bash tests/run_v9_5.sh");
assert.equal(packageJson.scripts["validate:browser"], "V9_BROWSER_SMOKE=1 bash tests/run_v9_5.sh");

console.log("V9.5: PASS (canonical REPD Ref news binder; V9.4 subtree frozen; 7,680-record data retained)");

Check V9 5 1

A JavaScript module in the tests folder of GlobalGrid2050 that tests major project news, homepage catalogue and the Renewable Energy Planning Database (REPD) register, using SHA-256.

testglobalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/check_v9_5_1.mjs · lines 1–229 of 229 · pattern reachable (shared by 4 files)

What it does
It tests major project news, homepage catalogue and the REPD register. Defines 6 functions or classes, including readText, readJson, sha256, gitBlob, gitTree. Uses libraries node:assert/strict, node:child_process, node:crypto, node:fs/promises, node:url. Side effects: changes the web page (DOM); reads or writes files; starts processes.
Why it exists in the grid workflow
Domain stage upstream_foresight (path word 'renewables'): upstream engineering foresight over GB transmission and distribution topology (TSO/DNO, 132kV and above, the REPD pipeline, data centres), which Ventus Ltd states it models for foresight. Domain terms in the code: the REPD register.
Inputs & outputs
In: JSON file release.v9.5.1.json; JSON file release.v9.5.json; JSON file release.v9.1.json; JSON file v9_manifest.json; JSON file build_manifest.json; JSON file major_project_news_v9_5_1.json; JSON file homepage-catalogue.json.
Downstream impact
Used directly by 1 file: Run V9 5 1 (globalgrid2050). Reached from 1 other entry point, including GlobalGrid2050 V9 5 1 Validate Workflow (globalgrid2050).
What it achieves
It reads text (`readText`) and reads JSON (`readJson`). Defines `readText`, `readJson`, `sha256` and 3 more. It reads `contracts/release.v9.5.1.json`.
Why it matters
Checked by Run V9 5 1.
Application
globalgrid2050 · uk_renewables_pipeline/v9.5.1/tests · JavaScript module
Uses
Projects V9 5 1 (script call), Project Filter V9 2 (import), UK Renewables Pipeline — V9 5 1 Page (new URL import.meta.url), node:assert/strict, node:child_process, node:crypto, node:fs/promises, node:url
Used by
run by Run V9 5 1 (script call)
Produces
readText, readJson, sha256, gitBlob, gitTree, reachable
Defines here
readText, readJson, sha256, gitBlob, gitTree, reachable
Cannot conclude
Whether this code runs, is used by a live app today, or is correct. This is a static reading.
Evidence
globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/v9.5.1/tests/check_v9_5_1.mjs:1-229 · blob 4a332d0d7aaf68818aeb5f6c2bc5ed233d78e658 · GitHub at these lines
State
achieves: name · context: readme_derived · stage: output · effects: dom, filesystem, process · domain stage: upstream_foresight · users: IPP_developer, ICP_grid_engineer · canonical: production_core
import assert from "node:assert/strict";
import { execFileSync } from "node:child_process";
import { createHash } from "node:crypto";
import { readFile } from "node:fs/promises";
import { fileURLToPath } from "node:url";
import {
  buildProjectSearchTextV9_2,
  projectMatchesV9_2,
  summariseProjectsV9_2,
  tokeniseSearchV9_2,
} from "../scripts/core/project-filter-v9-2.js";
import { atlasUrlV9_5_1, compareProjectUpdatesV9_5_1 } from "../scripts/plugins/projects-v9-5-1.js";

const base = new URL("../", import.meta.url);
const root = new URL("../../../", import.meta.url);
const rootPath = fileURLToPath(root);
const readText = (path) => readFile(new URL(path, base), "utf8");
const readJson = async (path) => JSON.parse(await readText(path));
const sha256 = (value) => createHash("sha256").update(value).digest("hex");
const gitBlob = (path) => execFileSync("git", ["-C", rootPath, "hash-object", path], { encoding: "utf8" }).trim();
const gitTree = (revisionPath) => execFileSync("git", ["-C", rootPath, "rev-parse", revisionPath], { encoding: "utf8" }).trim();

const contract = await readJson("contracts/release.v9.5.1.json");
const parentContract = await readJson("contracts/release.v9.5.json");
const dataContract = await readJson("contracts/release.v9.1.json");
const releaseManifest = await readJson("data/v9_manifest.json");
const payload = await readJson("data/v9.1/build_manifest.json");
const projectParts = await Promise.all(payload.project_partitions.map(({ path }) => readJson(path)));
const projects = projectParts.flatMap((part) => part.projects);
const news = JSON.parse(await readFile(new URL("dist/major_project_news_v9_5_1.json", root), "utf8"));

assert.equal(contract.release, "9.5.1");
assert.equal(contract.frozen_parent.release, "9.5");
assert.equal(contract.frozen_parent.commit, "3acd56386d0bf2952f8f26754d615d20a7345e35");
assert.equal(contract.frozen_parent.subtree, "c4024d08340528a57f7b890a1d96a0ca0a343916");
assert.equal(contract.frozen_parent.tree_listing_sha256, "ddb147828316c7fba73cd7af4c7bb5c63280fb77b5410a66483b9618d460e15e");
assert.equal(contract.frozen_parent.must_remain_unchanged, true);
assert.equal(gitTree("HEAD:uk_renewables_pipeline/v9.5"), contract.frozen_parent.subtree, "V9.5 subtree changed while building V9.5.1");
assert.equal(gitTree("HEAD:uk_renewables_pipeline/v9.4"), contract.frozen_v9_4.subtree, "V9.4 subtree changed while building V9.5.1");
assert.equal(contract.data_parent.release, "9.1");
assert.equal(contract.data_parent.data_changed, false);
assert.equal(parentContract.release, "9.5");
assert.equal(dataContract.release, "9.1");
assert.equal(releaseManifest.version, "9.5.1");
assert.ok(["CANDIDATE", "LIVE_VALIDATED"].includes(releaseManifest.status));
assert.equal(releaseManifest.frozen_v9_5_commit, contract.frozen_parent.commit);
assert.equal(releaseManifest.frozen_v9_5_subtree, contract.frozen_parent.subtree);
assert.equal(contract.ui_contract.first_click, "updated_desc");
assert.equal(contract.ui_contract.second_click, "updated_asc");
assert.equal(contract.ui_contract.aria_sort_default, "none");
assert.equal(contract.ui_contract.aria_sort_newest, "descending");
assert.equal(contract.ui_contract.aria_sort_oldest, "ascending");
assert.equal(contract.ui_contract.project_table_columns, 11);
assert.equal(contract.news_contract.all_headline_count, 133);
assert.equal(contract.news_contract.relevant_headline_count, 45);
assert.equal(contract.news_contract.v9_4_baseline_headline_count, 125);
assert.equal(contract.news_contract.relevant_filter_is_functional, true);
assert.equal(contract.news_contract.discovery_only_drives_project_signal, false);
assert.equal(contract.news_contract.beacon_fen.repd_ref, "13599");
assert.equal(contract.news_contract.beacon_fen.official_capacity_mw, 400);

const frozenV92Blobs = {
  "uk_renewables_pipeline/v9/scripts/core/project-filter-v9-2.js": "dceee01d0f51e85b071aef275250c1fb223eeba7",
  "uk_renewables_pipeline/v9/scripts/core/news-relevance-v9-2.js": "f8374bfd6f0c47e98ca1e7f2f3312c9281a34e8a",
  "uk_renewables_pipeline/v9/scripts/data/canonical-projects-v9-2.js": "e3d9b7bb0f39b813cf3b1f125467efbd6a021dda",
  "uk_renewables_pipeline/v9/scripts/plugins/gauges-v9-2.js": "1d081d2d9e1630912b912953cf18f431754f9e19",
  "uk_renewables_pipeline/v9/scripts/plugins/newspaper-v9-2.js": "6c72de9e9bd8f41bf525a32ca2436e53ddb466b0",
  "uk_renewables_pipeline/v9/scripts/plugins/projects-v9-2.js": "0e222ea75e9db8dc3e9f1e829a15ac3ee1ca0acf",
  "uk_renewables_pipeline/v9/styles/v9-2.css": "f4ac1a09145b0f4824e333ac2acbc767d84f2da6",
};
for (const [path, expected] of Object.entries(frozenV92Blobs)) {
  assert.equal(gitBlob(path), expected, `${path} changed after the frozen V9.2 checkpoint`);
}

assert.equal(payload.project_count, 7680);
assert.equal(payload.capacity_mw, 356474.09);
assert.equal(payload.largest_mw, 4100);
assert.equal(payload.geometry_count, 7652);
assert.equal(payload.missing_geometry_count, 28);
assert.equal(payload.solar_count, 3563);
assert.equal(payload.bess_count, 1609);
assert.equal(payload.wind_onshore_count, 2399);
assert.equal(payload.wind_offshore_count, 109);
assert.equal(projects.length, 7680);
assert.equal(new Set(projects.map((project) => project.repd_ref)).size, 7680);
assert.ok(projects.every((project) => project.capacity_mw >= 1));
assert.deepEqual(summariseProjectsV9_2(projects), { count: 7680, capacity_mw: 356474.09, largest_mw: 4100 });

const datedProjects = projects.filter((project) => project.repd_record_updated);
const undatedProjects = projects.filter((project) => !project.repd_record_updated);
assert.ok(datedProjects.length > 1);
assert.ok(datedProjects.every((project) => /^\d{4}-\d{2}-\d{2}$/.test(project.repd_record_updated)));
const newestFirst = [...projects].sort((left, right) => compareProjectUpdatesV9_5_1(left, right, "desc"));
const oldestFirst = [...projects].sort((left, right) => compareProjectUpdatesV9_5_1(left, right, "asc"));
assert.ok(newestFirst[0].repd_record_updated >= newestFirst[1].repd_record_updated);
assert.ok(oldestFirst[0].repd_record_updated <= oldestFirst[1].repd_record_updated);
if (undatedProjects.length) {
  assert.equal(newestFirst.at(-1).repd_record_updated, null);
  assert.equal(oldestFirst.at(-1).repd_record_updated, null);
}

const berwick = projects.find((project) => project.repd_ref === "9873");
assert.ok(berwick);
const searchText = buildProjectSearchTextV9_2(berwick);
assert.equal(projectMatchesV9_2(berwick, {
  technology: "wind_offshore",
  status: "All",
  county: "All",
  tokens: tokeniseSearchV9_2("GG2050-REPD-9873 Berwick"),
}, searchText), true);
assert.equal(projectMatchesV9_2(berwick, {
  technology: "solar",
  status: "All",
  county: "All",
  tokens: [],
}, searchText), false);

const validAtlas = new URL(atlasUrlV9_5_1(berwick));
assert.equal(validAtlas.searchParams.get("repd_ref"), "9873");
assert.equal(validAtlas.searchParams.get("technology"), "wind_offshore");
const missingGeometry = projects.find((project) => project.geometry_status !== "valid");
assert.ok(missingGeometry);
assert.equal(atlasUrlV9_5_1(missingGeometry), "");

assert.equal(news.schema, "globalgrid2050.major-project-news.v9.5.1");
assert.equal(news.all_headline_count, news.all_items.length);
assert.equal(news.relevant_headline_count, news.canonical_items.length);
assert.equal(news.all_items.length, 133);
assert.equal(news.canonical_items.length, 45);
assert.equal(news.v9_4_baseline_headline_count, 125);
assert.ok(news.canonical_items.every((item) => item.role === "PRIMARY_MATCH"));
assert.ok(news.canonical_items.every((item) => item.eligible_for_news_signal === true));
assert.ok(news.canonical_items.every((item) => item.gg_project_id === `GG2050-REPD-${item.repd_ref}`));
assert.equal(news.all_items.filter((item) => item.canonical_relevant).length, 45);
const beacon = news.canonical_items.find((item) => item.headline === "Beacon Fen Energy Park development consent decision announced");
assert.ok(beacon);
assert.equal(beacon.repd_ref, "13599");
assert.equal(beacon.capacity_mw, 400);
assert.equal(beacon.operator, "Low Carbon Limited");
const brecks = news.canonical_items.filter((item) => item.repd_ref === "10087");
assert.ok(brecks.length > 0);
assert.ok(brecks.every((item) => item.gg_development_id));

const html = await readText("index.html");
const mobileCss = await readText("styles/mobile.css");
const additiveCss = await readText("styles/v9-3.css");
const parentAdditiveCss = await readText("styles/v9-2.css");
const headerCss = await readText("styles/v9-4.css");
const responsiveCss = await readText("styles/v9-5-1.css");
const frozenParentCss = await readFile(new URL("uk_renewables_pipeline/v9/styles/v9-3.css", root), "utf8");
const projectsV95 = await readText("scripts/plugins/projects-v9-5-1.js");
const newspaperV95 = await readText("scripts/plugins/newspaper-v9-5-1.js");
const app = await readText("scripts/app-v9-5-1.js");
const catalogue = JSON.parse(await readFile(new URL("catalogue/homepage-catalogue.json", root), "utf8"));
const packageJson = await readJson("package.json");

assert.match(html, /UK RENEWABLES PIPELINE V9\.5\.1/);
assert.match(html, />V9\.5\.1 (?:CANDIDATE|LIVE)</);
assert.match(html, /V9\.5 FROZEN APP/);
assert.match(html, /V9\.4 FROZEN APP/);
const styleOrder = [
  html.indexOf("styles/v7.css?v=9.5.1"),
  html.indexOf("styles/mobile.css?v=9.5.1"),
  html.indexOf("styles/v9-3.css?v=9.5.1"),
  html.indexOf("styles/v9-4.css?v=9.5.1"),
  html.indexOf("styles/v9-5-1.css?v=9.5.1"),
];
assert.ok(styleOrder.every((value) => value >= 0));
assert.ok(styleOrder.every((value, index) => index === 0 || value > styleOrder[index - 1]));
assert.equal((html.match(/<canvas id="g[1-3]"/g) || []).length, 3);
assert.equal((html.match(/<th(?:\s|>)/g) || []).length, 11);
assert.match(html, /<th class="hide-mobile">REPD REF<\/th>/);
assert.match(html, /<th class="hide-mobile">GLOBALGRID REF<\/th>/);
assert.match(html, /id="repdUpdatedHeader" aria-sort="none"/);
assert.match(html, /id="sortUpdated"/);
assert.match(html, /id="updatedSortIndicator"[^>]*>↕<\/span>/);
assert.match(html, /id="sortProjects"/);
assert.match(html, /value="updated_desc"/);
assert.match(html, /value="updated_asc"/);
assert.match(html, /scripts\/app-v9-5-1\.js\?v=9\.5\.1/);

assert.equal(sha256(mobileCss), "9855b9c11255a85f477873d07cca45b057aedcdc8a6cc4aab2d29a0ffaac9b85");
assert.equal(additiveCss, frozenParentCss, "V9.4 changed its inherited V9.3.1 stylesheet copy");
const parentCssPrefix = parentAdditiveCss.trimEnd();
assert.ok(additiveCss.startsWith(parentCssPrefix), "V9.3 additive CSS no longer preserves the complete V9.2 prefix");
assert.match(headerCss, /\.repd-updated-heading button/);
assert.match(headerCss, /#updatedSortIndicator/);
assert.match(headerCss, /focus-visible/);
assert.match(responsiveCss, /@media\s*\(min-width:\s*921px\)\s*and\s*\(max-width:\s*1100px\)/);
assert.match(responsiveCss, /\.header\s*\{[^}]*flex-direction:\s*column[^}]*\}/s);
assert.match(responsiveCss, /\.status\s*\{[^}]*width:\s*100%[^}]*white-space:\s*normal[^}]*\}/s);

assert.match(app, /gauges-v9-2\.js/);
assert.match(app, /projects-v9-5-1\.js/);
assert.match(app, /newspaper-v9-5-1\.js/);
assert.match(projectsV95, /globalgrid2050_uk_renewables_pipeline_v9_5_1_/);
assert.match(projectsV95, /compareProjectUpdatesV9_5_1/);
assert.match(projectsV95, /function updateSortHeader\(\)/);
assert.match(projectsV95, /sortMode === "updated_desc" \? "updated_asc" : "updated_desc"/);
assert.match(projectsV95, /document\.getElementById\("sortUpdated"\)\.onclick/);
assert.match(projectsV95, /header\.setAttribute\("aria-sort", "descending"\)/);
assert.match(projectsV95, /header\.setAttribute\("aria-sort", "ascending"\)/);
assert.match(newspaperV95, /item\.role === "PRIMARY_MATCH"/);
assert.match(newspaperV95, /newsIndex\.get\(String\(project\.repd_ref\)\)/);
assert.match(newspaperV95, /major_project_news_v9_5_1\.json/);
assert.match(newspaperV95, /state\.newsMode === "RELEVANT" && item\.canonical_relevant !== true/);
assert.match(newspaperV95, /payload\.v9_4_baseline_headline_count === 125/);
assert.doesNotMatch(newspaperV95, /normaliseProject\(project\.name\)/);

/* REACHABILITY IS ASSERTED AGAINST THE CATALOGUE, NOT AGAINST index.html - see
   uk_renewables_pipeline/v9/tests/check_v9_3.mjs for the full reasoning. The
   homepage became a view over catalogue/homepage-catalogue.json on 2026-09-08
   and no longer names any version, so these matches failed on every push. The
   claim this gate protects - a reader can reach this published directory from
   the front door - is asserted against the data the front door reads. */
const reachable = (url) => catalogue.entries.some((e) => e.url === url);
assert.ok(reachable("./uk_renewables_pipeline/v9/"),
  "V9.3.1 is not listed in catalogue/homepage-catalogue.json; the reader cannot reach it");
assert.ok(reachable("./uk_renewables_pipeline/v9.4/"),
  "V9.4 is not listed in catalogue/homepage-catalogue.json; the reader cannot reach it");
assert.ok(reachable("./uk_renewables_pipeline/v9.5/"),
  "V9.5 is not listed in catalogue/homepage-catalogue.json; the reader cannot reach it");
assert.ok(reachable("./uk_renewables_pipeline/v9.5.1/"),
  "V9.5.1 is not listed in catalogue/homepage-catalogue.json; the reader cannot reach it");
assert.equal(packageJson.version, "9.5.1");
assert.equal(packageJson.scripts.validate, "bash tests/run_v9_5_1.sh");
assert.equal(packageJson.scripts["validate:browser"], "V9_BROWSER_SMOKE=1 bash tests/run_v9_5_1.sh");

console.log("V9.5.1: PASS (133 ALL, 45 RELEVANT, Beacon Fen REPD 13599; V9.5/V9.4 frozen)");

Run V9 5

A shell script in the tests folder of GlobalGrid2050.

Set aside from the main view: 94% of its lines are the same as uk_renewables_pipeline/202609051156/tests/run_v9_5.sh (globalgrid2050), which stays. (near-copy-of, proposed by families.py). 93% of lines shared with Run V9 5; read that one first. All set-aside files, with reasons. Nothing was deleted.

Evidence
  • line-jaccard 0.9355 to globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/202609051156/tests/run_v9_5.sh:1-38 673c227c75d9b97c4ded0f5f6da6e2d944066e07
  • sha256 0334e750fed69834708eb387b7cb1372c6c641821270fb45bdc7564d14666b7d
  • target sha256 e4d07f87aed1a4eabbecc2797de587e508ae1115dc8e6fea56aed163dba3d6f8
  • group of 2 (identity.json near-copy edges >= 0.9)
  • canonical rule: reachable, newest stamp, core repo, most lines

testglobalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/run_v9_5.sh · lines 1–38 of 38 · Entry point

What it does
It tests its inputs. Side effects: makes network requests; starts processes.
Why it exists in the grid workflow
Domain stage upstream_foresight (path word 'renewables'): upstream engineering foresight over GB transmission and distribution topology (TSO/DNO, 132kV and above, the REPD pipeline, data centres), which Ventus Ltd states it models for foresight.
Downstream impact
It is itself an entry point (shell script); no other file was found loading it.
What it achieves
No statement of purpose was found in the file, a README line naming it, or its name.
Why it matters
No other file in the estate was found to import it; it is an entry point.
Application
globalgrid2050 · uk_renewables_pipeline/v9.5.1/tests · shell script
Uses
Check V9 5 (script call)
Used by
none found
Produces
none declared
Defines here
none
Cannot conclude
Whether this code runs, is used by a live app today, or is correct. This is a static reading.
Evidence
globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/v9.5.1/tests/run_v9_5.sh:1-38 · blob 6cc6d11f8d203f5505a57bf47c51207c07db0234 · GitHub at these lines
State
achieves: name · context: readme_derived · stage: ingest · effects: network, process · domain stage: upstream_foresight · users: IPP_developer, ICP_grid_engineer · canonical: production_core
#!/usr/bin/env bash
set -euo pipefail

HERE="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
V95="$(cd "$HERE/.." && pwd)"
ROOT="$(cd "$V95/../.." && pwd)"

test "$(git -C "$ROOT" rev-parse 'HEAD:uk_renewables_pipeline/v9.4')" = "ae91e24c0f6e997ef4d9bd23dd70ea9779ea68b3"
python3 "$HERE/check_legacy_integrity_v9.py"
python3 "$V95/scripts/data/build_v9_1_spine.py"
git -C "$ROOT" diff --exit-code -- uk_renewables_pipeline/v9.4
git -C "$ROOT" diff --exit-code -- uk_renewables_pipeline/v9.5/data/v9.1
python3 "$ROOT/scripts/test_news_binder_v9_5.py"

while IFS= read -r source; do
  node --check "$source"
done < <(find "$V95/scripts" -type f -name '*.js' -print | sort)

node "$HERE/check_v9_5.mjs"

if [[ "${V9_BROWSER_SMOKE:-0}" == "1" ]]; then
  browser_base_url="${V9_BASE_URL:-http://127.0.0.1:8765/uk_renewables_pipeline/v9.5/}"
  python3 -m http.server 8765 --directory "$ROOT" >/tmp/globalgrid2050-v9-5-http.log 2>&1 &
  server_pid=$!
  trap 'kill "$server_pid" 2>/dev/null || true' EXIT
  for _ in {1..20}; do
    if curl --fail --silent --output /dev/null "$browser_base_url"; then
      break
    fi
    sleep 0.25
  done
  curl --fail --silent --output /dev/null "$browser_base_url"
  V9_BASE_URL="$browser_base_url" node "$HERE/browser_smoke_v9_5.mjs"
  kill "$server_pid" 2>/dev/null || true
  trap - EXIT
fi

echo "V9.5 validation suite: PASS ($ROOT)"

Run V9 5 1

A shell script in the tests folder of GlobalGrid2050.

testglobalgrid2050 / uk_renewables_pipeline/v9.5.1/tests/run_v9_5_1.sh · lines 1–43 of 43 · Entry point

What it does
It tests its inputs. Side effects: makes network requests; starts processes.
Why it exists in the grid workflow
Domain stage upstream_foresight (path word 'renewables'): upstream engineering foresight over GB transmission and distribution topology (TSO/DNO, 132kV and above, the REPD pipeline, data centres), which Ventus Ltd states it models for foresight.
Downstream impact
Used directly by 1 file: GlobalGrid2050 V9 5 1 Validate Workflow (globalgrid2050).
What it achieves
No statement of purpose was found in the file, a README line naming it, or its name.
Why it matters
Run by GlobalGrid2050 V9 5 1 Validate Workflow.
Application
globalgrid2050 · uk_renewables_pipeline/v9.5.1/tests · shell script
Uses
Check V9 5 1 (script call)
Used by
run by GlobalGrid2050 V9 5 1 Validate Workflow (workflow run)
Produces
none declared
Defines here
none
Cannot conclude
Whether this code runs, is used by a live app today, or is correct. This is a static reading.
Evidence
globalgrid2050@0aca5121f0795e469b6cf4fc3d3b628edba8d883 uk_renewables_pipeline/v9.5.1/tests/run_v9_5_1.sh:1-43 · blob 9ec36c14c5b51b64c2209ce8e10cabe10b0beec4 · GitHub at these lines
State
achieves: name · context: readme_derived · stage: ingest · effects: network, process · domain stage: upstream_foresight · users: IPP_developer, ICP_grid_engineer · canonical: production_core
#!/usr/bin/env bash
set -euo pipefail

HERE="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
V951="$(cd "$HERE/.." && pwd)"
ROOT="$(cd "$V951/../.." && pwd)"

test "$(git -C "$ROOT" rev-parse 'HEAD:uk_renewables_pipeline/v9.4')" = "ae91e24c0f6e997ef4d9bd23dd70ea9779ea68b3"
test "$(git -C "$ROOT" rev-parse 'HEAD:uk_renewables_pipeline/v9.5')" = "c4024d08340528a57f7b890a1d96a0ca0a343916"
python3 "$HERE/check_legacy_integrity_v9.py"
python3 "$V951/scripts/data/build_v9_1_spine.py"
git -C "$ROOT" diff --exit-code -- uk_renewables_pipeline/v9.4
git -C "$ROOT" diff --exit-code -- uk_renewables_pipeline/v9.5
git -C "$ROOT" diff --exit-code -- uk_renewables_pipeline/v9.5.1/data/v9.1
python3 "$ROOT/scripts/test_news_binder_v9_5.py"
python3 "$ROOT/scripts/build_news_feed_v9_5_1.py"
git -C "$ROOT" diff --exit-code -- dist/major_project_news_v9_5_1.json
python3 "$ROOT/scripts/test_news_feed_v9_5_1.py"

while IFS= read -r source; do
  node --check "$source"
done < <(find "$V951/scripts" -type f -name '*.js' -print | sort)

node "$HERE/check_v9_5_1.mjs"

if [[ "${V9_BROWSER_SMOKE:-0}" == "1" ]]; then
  browser_base_url="${V9_BASE_URL:-http://127.0.0.1:8765/uk_renewables_pipeline/v9.5.1/}"
  python3 -m http.server 8765 --directory "$ROOT" >/tmp/globalgrid2050-v9-5-1-http.log 2>&1 &
  server_pid=$!
  trap 'kill "$server_pid" 2>/dev/null || true' EXIT
  for _ in {1..20}; do
    if curl --fail --silent --output /dev/null "$browser_base_url"; then
      break
    fi
    sleep 0.25
  done
  curl --fail --silent --output /dev/null "$browser_base_url"
  V9_BASE_URL="$browser_base_url" node "$HERE/browser_smoke_v9_5_1.mjs"
  kill "$server_pid" 2>/dev/null || true
  trap - EXIT
fi

echo "V9.5.1 validation suite: PASS ($ROOT)"