mirror of
https://github.com/Gathin23/cleanyourtv.git
synced 2026-11-04 20:56:39 +00:00
The three scripts that draw README's card read sys.argv[1], sys.argv[2] at the top of the module, so a run with no arguments died on IndexError, and press.md's Fredoka.ttf - a Google Fonts file no folder of this repo holds - died inside Pillow on 'OSError: cannot open resource'. One font_and_out() guard per script, before the Pillow import; gen_tables.py --font refuses a missing path itself instead of wrapping their message in CalledProcessError; press.md says where the font comes from. The one test that ran gen_tables.py --check on this tree and demanded exit 0 is gone: the tables are stale on any branch that adds a list folder, which docs/workflows/tv-list.md tells a list PR to do and leaves to a maintainer after merging, so that assertion would have been red on every list PR. In its place, --check must give the same verdict with and without --font.
1.2 KiB
1.2 KiB
Workflow: Add a press entry
When to use this: an article about this project.
- Add a row
| Outlet | [Headline](<url>) | Date |to the right country section ofdocs/PRESS.md, in the headline's own language. The link must open and show the article: no syndicated copies, no auto-generated listings, nothing that cannot be checked. - Update the counts in all four places
tests/test_press_counts.pychecks: thedocs/PRESS.mdintro line, its index line, the README card's alt text ("and N more: N articles from N countries") andMOREintools/readme_featured.py. Redrawingdocs/featured.pnganddocs/card.jpgneeds Pillow, which the performance requirements install:tools/venv/bin/pip install -r tools/requirements-perf.txt, thentools/readme_featured.py Fredoka.ttf docs/featured.pngandtools/readme_card.py Fredoka.ttf docs/card.jpg. Fredoka is the variable TTF from Google Fonts and its file is not in the repo, so that first argument is the path of the copy you downloaded; each script says so when the path is wrong. If you cannot redraw them, say so in the PR.
Then run the tests: python3 -m unittest discover -s tests -v.