From dd75c52df467341fb4a18a23ed8abd21428e1483 Mon Sep 17 00:00:00 2001 From: Matt McKay Date: Thu, 16 Jul 2026 13:41:04 +1000 Subject: [PATCH 1/2] Retire the last references to the retired lecture-python repo MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit pandas_panel read all three of realwage.csv, countries.csv and employ.csv from QuantEcon/lecture-python — a repo last touched in January 2022 — even though this repo already has its own committed copies of all three under _static/lecture_specific/pandas_panel/. Now it reads its own. Verified byte-identical before repointing: each own-repo copy has the same sha256 as the legacy file it replaces, and the new URLs serve those same bytes, so lecture output cannot change. Mirrors QuantEcon/lecture-python.myst#968, which did the same for the myst series. With this, no English lecture source in the Python family points at the retired repo except lecture-stats. Interim by design: P2 of the datasets pilot migrates this trio to QuantEcon/data-lectures and will rewrite these three lines again — but it rewrites them either way, so this costs P2 nothing and stops the lecture depending on an unmaintained repo meanwhile. Part of QuantEcon/meta#337 See QuantEcon/meta#336 Co-Authored-By: Claude Fable 5 --- lectures/pandas_panel.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lectures/pandas_panel.md b/lectures/pandas_panel.md index fcb44255..f97b068a 100644 --- a/lectures/pandas_panel.md +++ b/lectures/pandas_panel.md @@ -77,7 +77,7 @@ countries and assign it to `realwage`. The dataset can be accessed with the following link: ```{code-cell} ipython3 -url1 = 'https://raw.githubusercontent.com/QuantEcon/lecture-python/master/source/_static/lecture_specific/pandas_panel/realwage.csv' +url1 = 'https://github.com/QuantEcon/lecture-python-programming/raw/refs/heads/main/lectures/_static/lecture_specific/pandas_panel/realwage.csv' ``` ```{code-cell} ipython3 @@ -197,7 +197,7 @@ function. The dataset can be accessed with the following link: ```{code-cell} ipython3 -url2 = 'https://raw.githubusercontent.com/QuantEcon/lecture-python/master/source/_static/lecture_specific/pandas_panel/countries.csv' +url2 = 'https://github.com/QuantEcon/lecture-python-programming/raw/refs/heads/main/lectures/_static/lecture_specific/pandas_panel/countries.csv' ``` ```{code-cell} ipython3 @@ -506,7 +506,7 @@ in Europe by age and sex from [Eurostat](https://ec.europa.eu/eurostat/data/data The dataset can be accessed with the following link: ```{code-cell} ipython3 -url3 = 'https://raw.githubusercontent.com/QuantEcon/lecture-python/master/source/_static/lecture_specific/pandas_panel/employ.csv' +url3 = 'https://github.com/QuantEcon/lecture-python-programming/raw/refs/heads/main/lectures/_static/lecture_specific/pandas_panel/employ.csv' ``` Reading in the CSV file returns a panel dataset in long format. Use `.pivot_table()` to construct From f6ef5b8dcd8ca493c246538afeb90bb3474e1124 Mon Sep 17 00:00:00 2001 From: Matt McKay Date: Thu, 16 Jul 2026 13:54:05 +1000 Subject: [PATCH 2/2] Use this repo's existing raw.githubusercontent URL form MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Addresses Copilot review on #576. The repoint used github.com/.../raw/refs/heads/main/..., which introduced a third URL form into a repo that already had one: pandas.md and the other own-data reads all use raw.githubusercontent.com/.../main/.... Now all five own-data URLs match. Both forms fetch these files correctly — checked, they parse to identical frames — so this is about consistency, not correctness. Copilot's stated reason (that the redirect makes /raw/ less reliable for read_csv) does not hold; the redirect is real but pandas follows it. The one thing /raw/ buys is LFS safety: raw.githubusercontent.com serves pointer text rather than data for LFS-tracked files. That does not apply here — this repo has no .gitattributes, nothing is LFS — and these three files move to data-lectures under pilot P2 regardless, which is where the LFS-safe form actually matters. Part of QuantEcon/meta#337 Co-Authored-By: Claude Fable 5 --- lectures/pandas_panel.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lectures/pandas_panel.md b/lectures/pandas_panel.md index f97b068a..f61186a9 100644 --- a/lectures/pandas_panel.md +++ b/lectures/pandas_panel.md @@ -77,7 +77,7 @@ countries and assign it to `realwage`. The dataset can be accessed with the following link: ```{code-cell} ipython3 -url1 = 'https://github.com/QuantEcon/lecture-python-programming/raw/refs/heads/main/lectures/_static/lecture_specific/pandas_panel/realwage.csv' +url1 = 'https://raw.githubusercontent.com/QuantEcon/lecture-python-programming/main/lectures/_static/lecture_specific/pandas_panel/realwage.csv' ``` ```{code-cell} ipython3 @@ -197,7 +197,7 @@ function. The dataset can be accessed with the following link: ```{code-cell} ipython3 -url2 = 'https://github.com/QuantEcon/lecture-python-programming/raw/refs/heads/main/lectures/_static/lecture_specific/pandas_panel/countries.csv' +url2 = 'https://raw.githubusercontent.com/QuantEcon/lecture-python-programming/main/lectures/_static/lecture_specific/pandas_panel/countries.csv' ``` ```{code-cell} ipython3 @@ -506,7 +506,7 @@ in Europe by age and sex from [Eurostat](https://ec.europa.eu/eurostat/data/data The dataset can be accessed with the following link: ```{code-cell} ipython3 -url3 = 'https://github.com/QuantEcon/lecture-python-programming/raw/refs/heads/main/lectures/_static/lecture_specific/pandas_panel/employ.csv' +url3 = 'https://raw.githubusercontent.com/QuantEcon/lecture-python-programming/main/lectures/_static/lecture_specific/pandas_panel/employ.csv' ``` Reading in the CSV file returns a panel dataset in long format. Use `.pivot_table()` to construct