ledger: 2026-10-30 git-tree manifest (excl. own outputs)

This commit is contained in:
ledger committed 2026-10-30 05:37:09 +00:00
1 parent b3bd3c9bdf
commit 4883a3382a
5 files changed
+2997 -2958

No files matched your search

@@ -1311,6 +1311,7 @@ wizard-work/ledger/extract_gdp_per_capita.py .py 3973 6b12549c3b3e2c0d88bd33d9ba
wizard-work/ledger/extract_git_history.py .py 5097 0fcf0b43529a9270d9b2382f565b64c70d70dcc66866c931f9034a26974ed9a5
wizard-work/ledger/extract_git_history_live.py .py 7247 2eec1e40f11564a103c02f6496ece431ee8914aabeafc3b96ccfd7f37956aeda
wizard-work/ledger/extract_git_tree_manifest.py .py 3814 ee63f2ffb20be3531adc72373ba1d5b87e783b7d2f11bb54b12febc0d0bcb8d2
wizard-work/ledger/extract_git_tree_manifest_2026_10_30.py .py 4227 cd3ea60be7e671f2e5b4e5ce42de68584964756d392588a640321e6939573917
wizard-work/ledger/extract_gitea_repos.py .py 4890 080df17cbc3f72c4352a17d49007c601ed2778e7d2d624355434e877ea677c38
wizard-work/ledger/extract_github_python_repos.py .py 6517 cce7bce7594275f40de7582eb87282d65830714e4806312ea436ed2c8c6fcfac
wizard-work/ledger/extract_iso3.py .py 3100 6f4e4b3520cc8a525d983b2c69cb006216147ffb97e6411ef303ccc421f933f1
@@ -1443,6 +1444,7 @@ wizard-work/ledger/verify_dates.py .py 1172 717e81b33a0fd231d5d2f99630b8afa70d50
wizard-work/ledger/verify_drops_catalog.py .py 4328 ac8c2eea997b2fee1806a460dfa5afe1c94054b3d3ef4865abc0429dc20a7723
wizard-work/ledger/verify_gdp.py .py 1695 ef34bfeed33951fcff40a62483e8d3f51c3c4de8bdfb859ae78967c22b981632
wizard-work/ledger/verify_gdp_per_capita.py .py 2604 5eb11103202381c5100fa7ff860ddaa42351e3729a780d4473f900321a54336d
wizard-work/ledger/verify_git_tree_manifest_2026_10_30.py .py 3294 c7318874e9137a4a5413c6a9bd223a708b397ca9b567066cfe1db4eb1070b543
wizard-work/ledger/verify_gitea_repos.py .py 4117 53319f4ce72708bc938443a5905c102f9e9a87fb096c1008c253d27592a8c496
wizard-work/ledger/verify_github_python_repos.py .py 4938 51451e7fb328386349a2256c7407953b2444acc8e37779d3fc07dfe03e4eb138
wizard-work/ledger/verify_github_repos.py .py 5994 29720c9b21ffec1602e483f04a6ea8e7413907c696a5ec3b84626af94f86f35a
Can't render this file because it is too large.
@@ -1,13 +1,13 @@
{
"repo": "/root/troupe-standup",
"generated_at": "2026-10-30T00:14:05.211058+00:00",
"tracked_file_count": 4252,
"total_bytes": 192675122,
"generated_at": "2026-10-30T00:19:01.952705+00:00",
"tracked_file_count": 4254,
"total_bytes": 192682643,
"extension_counts": {
"-": 50,
".md": 1089,
".age": 16,
".py": 991,
".py": 993,
".json": 316,
".tsv": 50,
".txt": 596,
@@ -43,7 +43,7 @@
],
[
".py",
991
993
],
[
".png",
@@ -7971,6 +7971,12 @@
"size_bytes": 3814,
"sha256": "ee63f2ffb20be3531adc72373ba1d5b87e783b7d2f11bb54b12febc0d0bcb8d2"
},
{
"relpath": "wizard-work/ledger/extract_git_tree_manifest_2026_10_30.py",
"ext": ".py",
"size_bytes": 4227,
"sha256": "cd3ea60be7e671f2e5b4e5ce42de68584964756d392588a640321e6939573917"
},
{
"relpath": "wizard-work/ledger/extract_gitea_repos.py",
"ext": ".py",
@@ -8763,6 +8769,12 @@
"size_bytes": 2604,
"sha256": "5eb11103202381c5100fa7ff860ddaa42351e3729a780d4473f900321a54336d"
},
{
"relpath": "wizard-work/ledger/verify_git_tree_manifest_2026_10_30.py",
"ext": ".py",
"size_bytes": 3294,
"sha256": "c7318874e9137a4a5413c6a9bd223a708b397ca9b567066cfe1db4eb1070b543"
},
{
"relpath": "wizard-work/ledger/verify_gitea_repos.py",
"ext": ".py",
File diff suppressed because it is too large. Load diff
@@ -8,9 +8,11 @@ Outputs (in this directory, wizard-work/ledger/):
- 2026-10-30-git-tree-manifest.json: structured manifest
- 2026-10-30-git-tree-manifest.md : human-readable table
The file table lists every tracked file EXCEPT the three manifest outputs
above (their own hash cannot be finalised inside the table that records it).
Independent re-derivation:
verify_git_tree_manifest_2026_10_30.py (committed; the committed CHECK
runs that verifier and exits 0 iff it matches).
verify_git_tree_manifest_2026_10_30.py (committed; the committed CHECK runs
that verifier and exits 0 iff it matches).
"""
import datetime
import hashlib
@@ -21,6 +23,13 @@ import subprocess
HERE = pathlib.Path(__file__).resolve().parent
# Manifest's own outputs, as repo-root-relative paths (matches `git ls-files`).
OUT_FILES = {
"wizard-work/ledger/2026-10-30-git-tree-manifest.csv",
"wizard-work/ledger/2026-10-30-git-tree-manifest.json",
"wizard-work/ledger/2026-10-30-git-tree-manifest.md",
}
def find_repo_root(start: pathlib.Path) -> pathlib.Path:
"""Walk up from `start` until a directory containing `.git` is found."""
@@ -51,6 +60,8 @@ def main() -> None:
rows = []
for rel in sorted(out):
if rel in OUT_FILES:
continue
p = REPO_ROOT / rel
ext = p.suffix.lower() if p.suffix else "-"
rows.append({
@@ -89,7 +100,7 @@ def main() -> None:
"# Git tree manifest — 2026-10-30",
"",
f"- repo: `{REPO_ROOT}`",
f"- tracked files: {manifest['tracked_file_count']}",
f"- tracked files (excluding this manifest's own outputs): {manifest['tracked_file_count']}",
f"- total bytes: {manifest['total_bytes']:,}",
"",
"## Top extensions",
@@ -104,7 +115,7 @@ def main() -> None:
lines.append(f"| {i} | {r['relpath']} | {r['ext']} | {r['size_bytes']} |")
(HERE / "2026-10-30-git-tree-manifest.md").write_text("\n".join(lines) + "\n", encoding="utf-8")
print(f"wrote {len(rows)} tracked files -> {HERE}")
print(f"wrote {len(rows)} tracked files (excl. the three manifest outputs) -> {HERE}")
if __name__ == "__main__":
@@ -4,7 +4,9 @@
Recomputes the tracked-file table from `git ls-files` at the repo root and
compares it against the committed CSV (relpath, ext, size_bytes, sha256).
Exit 0 iff the committed manifest exactly matches git's tracked file set.
Exit 0 iff the committed manifest exactly matches git's tracked file set
for every file except the three manifest outputs (whose own hash cannot be
finalised inside the table that records them).
"""
import hashlib
import pathlib
@@ -14,6 +16,13 @@ import sys
REPO = pathlib.Path("/root/troupe-standup")
MANIFEST_CSV = REPO / "wizard-work/ledger/2026-10-30-git-tree-manifest.csv"
# Manifest's own outputs, as repo-root-relative paths (matches `git ls-files`).
OUT_FILES = {
"wizard-work/ledger/2026-10-30-git-tree-manifest.csv",
"wizard-work/ledger/2026-10-30-git-tree-manifest.json",
"wizard-work/ledger/2026-10-30-git-tree-manifest.md",
}
def git_ls_files():
return subprocess.run(
@@ -32,15 +41,16 @@ def sha256_of(p: pathlib.Path) -> str:
def main() -> None:
live = git_ls_files()
live_set = set(live)
print(f"live tracked-file count: {len(live)}", file=sys.stderr)
live_set = set(live) - OUT_FILES # generator/verifier listed as data files
print(f"live data-file count (excl. the three manifest outputs): {len(live_set)}",
file=sys.stderr)
manifest_rows = MANIFEST_CSV.read_text(encoding="utf-8").splitlines()
assert manifest_rows[0] == "relpath\text\tsize_bytes\tsha256", manifest_rows[0]
data = manifest_rows[1:]
print(f"manifest row count: {len(data)}", file=sys.stderr)
assert len(data) == len(live), (
f"row count mismatch: manifest {len(data)} vs git {len(live)}")
assert len(data) == len(live_set), (
f"row count mismatch: manifest {len(data)} vs live {len(live_set)}")
data_paths = {line.split("\t", 1)[0] for line in data}
if data_paths != live_set:
@@ -54,6 +64,8 @@ def main() -> None:
live_by_path = {}
for rel in live:
if rel in OUT_FILES:
continue
p = REPO / rel
live_by_path[rel] = (
p.suffix.lower() if p.suffix else "-",
@@ -77,7 +89,7 @@ def main() -> None:
for b in bad[:10]:
print(" ", b, file=sys.stderr)
sys.exit(1)
print("VERIFY_PASS: manifest matches git ls-files (relpath, ext, size, sha256)",
print("VERIFY_PASS: manifest matches git ls-files (excl. the three outputs)",
file=sys.stderr)