chore(meta): wiki sweep — 2,131 dead heightmap links, nav refresh, GOVERNANCE reality (T-1070, T-1071)

- T-1070: scaffold_bodies.py heightmap link now conditional (bake criteria
  per import_heightmaps.py); surgical removal of the dead image line from
  all 2,131 body pages lacking the file (267 with the file keep theirs)
- T-1071: 26 real link breaks fixed (knowledge/→concepts/, pre-governance
  decision anchors, 9 phantom catalog companions unlinked, cygni relink to
  the corporation page, wrong design-doc path); wiki/index.md counts fixed
  (301 systems) + Economics nav section; corporations/index.md regenerated
  from frontmatter (all 155, tier1.toml grouping — corrects 4 misfiled
  tier-1 corps); 25 orphaned station GTTRs linked from 11 system pages
  (own ##-heading so atlas sync cannot absorb it); GOVERNANCE.md +
  star-system template rewritten to the generated model (DB owns
  structured fields, wiki owns prose); triangles/index.md added
- Sol markers conversion REVERTED before commit: atlas_viewer.gd:433 still
  renders the legacy geometry schema, so conversion would drop Sol's Atlas
  overlays — split to T-1073 (convert together with the client read path)

Broken relative links: 2,180 → 25 (all remaining are intentional
_templates/ placeholders).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-06-12 16:23:16 +02:00
co-authored by Claude Fable 5
parent 346d87df7a
commit b4919c659b
2156 changed files with 373 additions and 4391 deletions
+14 -5
View File
@@ -78,7 +78,7 @@ def _body_prose(bd: dict, system_dir: Path) -> str:
if btype == "moon":
lines.append(f"{pclass.replace('_', ' ').title()} moon.")
elif pclass in ("gas_giant", "gas_giant_ringed"):
lines.append(f"Gas giant.")
lines.append("Gas giant.")
else:
lines.append(f"{pclass.replace('_', ' ').title()} {btype}.")
lines.append("")
@@ -90,11 +90,20 @@ def _body_prose(bd: dict, system_dir: Path) -> str:
# Visual overview
lines.append("## Visual")
lines.append("")
lines.append(f"![Globe](globe.png)")
lines.append("![Globe](globe.png)")
lines.append("")
# Heightmap link only when the file exists or will exist: import_heightmaps.py
# bakes heightmap.png solely for non-Sol, non-gas inhabited bodies with
# population > 0 (D-202 amended, #963) — linking it elsewhere produces a
# dead image.
if pclass not in ("gas_giant", "gas_giant_ringed"):
lines.append(f"![Heightmap](heightmap.png)")
lines.append("")
heightmap_path = system_dir / "bodies" / bid / "heightmap.png"
will_exist = (system_dir.name != "GJ-0"
and bool(wiki.get("inhabited"))
and bool(wiki.get("population")))
if heightmap_path.exists() or will_exist:
lines.append("![Heightmap](heightmap.png)")
lines.append("")
# Profile table
lines.append("## Profile")
@@ -118,7 +127,7 @@ def _body_prose(bd: dict, system_dir: Path) -> str:
label = "Orbit" if btype == "moon" else "Year"
lines.append(f"| **{label}** | {orbit['period_days']:.0f} days |")
if wiki.get("inhabited"):
lines.append(f"| **Inhabited** | yes |")
lines.append("| **Inhabited** | yes |")
if wiki.get("population"):
lines.append(f"| **Population** | {wiki['population']} |")
if wiki.get("economy"):