Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 16 additions & 16 deletions CATALOG.md

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions lectures/ames_house_prices.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ consumers:
file: lectures/observed_distributions.md
- repo: QuantEcon/lecture-python-intro
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/observed_distributions.md

builder: builders/ames_house_prices.py
builder_status: committed
14 changes: 10 additions & 4 deletions lectures/assignat.xlsx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,15 +103,21 @@ schema:
row_count_floor: null # per-range, declared above
known_nulls: {}

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/french_rev.md
- repo: QuantEcon/lecture-wasm
file: lectures/french_rev.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/french_rev.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/french_rev.md

builder: null
builder_status: not-applicable # verbatim republication -- nothing to build
19 changes: 15 additions & 4 deletions lectures/caron.npy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,15 +90,26 @@ schema:
of this array with rows 14:77 of nom_balances.npy. Changing the length of
either silently misaligns the other.

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/french_rev.md
- repo: QuantEcon/lecture-wasm
file: lectures/french_rev.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/french_rev.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/french_rev.md
note: >
Reads a local `datasets/` copy, not this file. A PARTIAL repoint: the
three .xlsx reads in the same lecture were repointed and these two .npy
reads were not, and the lecture is outside the canary's build set so
nothing fails. Tracked in QuantEcon/workspace-lectures#46.

# ---------------------------------------------------------------------------
# Builder
Expand Down
14 changes: 10 additions & 4 deletions lectures/chapter_3.xlsx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,15 +90,21 @@ schema:
map to strip whitespace and handle footnote markers), so dtypes are not
stable across sheets and are deliberately not asserted here.

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/inflation_history.md
- repo: QuantEcon/lecture-wasm
file: lectures/inflation_history.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/inflation_history.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/inflation_history.md

# ---------------------------------------------------------------------------
# Builder
Expand Down
2 changes: 2 additions & 0 deletions lectures/countries.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ consumers:
file: lectures/pandas_panel.md
- repo: QuantEcon/lecture-python.myst
file: lectures/pandas_panel.md
- repo: QuantEcon/lecture-python.zh-cn
file: lectures/pandas_panel.md

# verbatim — no builder
builder_status: not-applicable
14 changes: 10 additions & 4 deletions lectures/dette.xlsx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,21 @@ schema:
sparse layouts in a working spreadsheet, and the lecture indexes specific
columns out of them rather than consuming the block whole.

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/french_rev.md
- repo: QuantEcon/lecture-wasm
file: lectures/french_rev.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/french_rev.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/french_rev.md

builder: null
builder_status: not-applicable # verbatim republication -- nothing to build
2 changes: 2 additions & 0 deletions lectures/employ.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@ consumers:
file: lectures/pandas_panel.md
- repo: QuantEcon/lecture-python.myst
file: lectures/pandas_panel.md
- repo: QuantEcon/lecture-python.zh-cn
file: lectures/pandas_panel.md

builder: null
builder_status: unrecovered # inherited constructed file (PLAN Phase 9)
2 changes: 2 additions & 0 deletions lectures/epl_match_goals.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ schema:
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/fitting_distributions.md

builder: builders/epl_match_goals.py
builder_status: committed
14 changes: 10 additions & 4 deletions lectures/fig_3.xlsx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,15 +83,21 @@ schema:
row_count_floor: 30 # exact by design -- a frozen 30-row block
known_nulls: {} # declared per column above

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/french_rev.md
- repo: QuantEcon/lecture-wasm
file: lectures/french_rev.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/french_rev.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/french_rev.md

builder: null
builder_status: not-applicable # verbatim republication -- nothing to build
4 changes: 4 additions & 0 deletions lectures/japan_deaths_by_age.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ consumers:
file: lectures/observed_distributions.md
- repo: QuantEcon/lecture-python-intro
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/observed_distributions.md

builder: builders/japan_deaths_by_age.py
builder_status: committed
2 changes: 2 additions & 0 deletions lectures/japan_earthquakes.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,8 @@ schema:
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/fitting_distributions.md

builder: builders/japan_earthquakes.py
builder_status: committed
14 changes: 10 additions & 4 deletions lectures/longprices.xls.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,21 @@ schema:
row_count_floor: 401 # frozen historical extract: exact by design
known_nulls: {} # declared per sheet above

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/inflation_history.md
- repo: QuantEcon/lecture-wasm
file: lectures/inflation_history.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/inflation_history.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/inflation_history.md

builder: null
builder_status: not-applicable # verbatim republication -- nothing to build
14 changes: 10 additions & 4 deletions lectures/mpd2020.xlsx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,16 +134,22 @@ schema:
# ---------------------------------------------------------------------------
# Consumers -- how a correction knows what to rebuild
# ---------------------------------------------------------------------------
# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").

consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/long_run_growth.md
- repo: QuantEcon/lecture-wasm
file: lectures/long_run_growth.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/long_run_growth.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/long_run_growth.md

# ---------------------------------------------------------------------------
# Builder
Expand Down
19 changes: 15 additions & 4 deletions lectures/nom_balances.npy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,26 @@ schema:
(late 1789 through 1790) exist to extend the circulation series before the
price series begins, and must not be trimmed.

# Every lecture that reads this file FROM THIS REPO. Empty does not mean the
# file is unused -- it may still be consumed from a lecture repo's own copy,
# which is exactly what a repoint moves. Populated in the repoint PR, at the
# same time migration.yml flips to `repointed` (PLAN, "Repoint rules").
# Every lecture that CONSUMES this dataset. The list answers "what must be
# rebuilt if these bytes change", so it also names a consumer that still reads
# a local copy rather than this repo -- such an entry carries a `note` saying
# so, and is the only machine-readable trace of that divergence. Empty means
# nothing consumes it yet. Populated in the repoint PR, at the same time
# migration.yml flips to `repointed` (PLAN, "Repoint rules").
consumers:
- repo: QuantEcon/lecture-python-intro
file: lectures/french_rev.md
- repo: QuantEcon/lecture-wasm
file: lectures/french_rev.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/french_rev.md
- repo: QuantEcon/test-actions-lecture-intro
file: lectures/french_rev.md
note: >
Reads a local `datasets/` copy, not this file. A PARTIAL repoint: the
three .xlsx reads in the same lecture were repointed and these two .npy
reads were not, and the lecture is outside the canary's build set so
nothing fails. Tracked in QuantEcon/workspace-lectures#46.

# ---------------------------------------------------------------------------
# Builder
Expand Down
2 changes: 2 additions & 0 deletions lectures/realwage.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ consumers:
file: lectures/pandas_panel.md
- repo: QuantEcon/lecture-python.myst
file: lectures/pandas_panel.md
- repo: QuantEcon/lecture-python.zh-cn
file: lectures/pandas_panel.md

builder: null
builder_status: unrecovered # inherited constructed file (PLAN Phase 9)
11 changes: 11 additions & 0 deletions lectures/us_adult_heights.csv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,17 @@ consumers:
file: lectures/observed_distributions.md
- repo: QuantEcon/lecture-python-intro
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/fitting_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/observed_distributions.md
- repo: QuantEcon/lecture-intro.zh-cn
file: lectures/prob_dist.md
note: >
Reads a local `_static/lecture_specific/prob_dist/` copy, not this file,
under a comment that still says to switch once the datasets repo exists.
The same repo's other two reads of this dataset WERE repointed. The copy
is byte-identical. Tracked in QuantEcon/workspace-lectures#46.

builder: builders/us_adult_heights.py
builder_status: committed
18 changes: 18 additions & 0 deletions manifest-schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,24 @@ schema:
consumers: []
# - repo: QuantEcon/lecture-python-intro
# file: lectures/business_cycle.md
#
# A consumer that does NOT yet read this repo — one still pointing at a local
# copy — is listed anyway, because the question this field answers is "what
# must be rebuilt if these bytes change", not "who is repointed". Say so in a
# `note`, which is what makes the divergence machine-readable rather than a
# YAML comment nobody can check, and cite the issue tracking the repoint with
# a FULLY QUALIFIED reference, since a bare `#N` or a workspace shorthand
# means nothing when read from this repo:
#
# - repo: QuantEcon/test-actions-lecture-intro
# file: lectures/french_rev.md
# note: >
# Reads a local `datasets/` copy, not this file.
# Tracked in QuantEcon/workspace-lectures#46.
#
# The generated catalog surfaces `note` beside the consumer, so a reader of
# CATALOG.md's "Used by" column cannot mistake a local-copy reader for a
# repointed one.

# ---------------------------------------------------------------------------
# Builder — required for constructed and dynamic-snapshot; omit for verbatim
Expand Down
18 changes: 16 additions & 2 deletions scripts/build_catalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,13 @@ def load_manifests():


def fmt_consumers(consumers) -> str:
"""Render the "Used by" cell.

A consumer may carry a `note` — it is listed because a correction to these
bytes must reach it, but it does not necessarily read THIS repo yet. Without
surfacing the note, the column reads as "these lectures fetch this file",
which is exactly the wrong inference for a consumer still on a local copy.
"""
if not consumers:
return "—"
parts = []
Expand All @@ -76,9 +83,16 @@ def fmt_consumers(consumers) -> str:
file = c.get("file", "")
stem = file.split("/")[-1] if file else ""
if repo and file:
parts.append(f"[{short} · {stem}](https://github.com/{repo}/blob/main/{file})")
label = f"[{short} · {stem}](https://github.com/{repo}/blob/main/{file})"
else:
parts.append(f"{short} · {stem}".strip(" ·"))
label = f"{short} · {stem}".strip(" ·")
note = " ".join((c.get("note") or "").split())
if note:
# First sentence only: enough to stop the wrong inference, short
# enough not to blow out a table cell. The manifest holds the rest.
head = note.split(". ")[0].rstrip(".")
label += f"<br><sub>⚠️ {head}</sub>"
parts.append(label)
return "<br>".join(parts)


Expand Down
Loading