Skip to content

Utilities to parse RSS feeds and make markdown stubs #301

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

banesullivan
Copy link
Contributor

@banesullivan banesullivan commented Aug 7, 2025

This adds utilities to create Markdown stubs from an RSS feed URL exposed through a CLI command like the other scripts for fetching data for the website.

The new CLI command is fetch-rss-feed and it takes an RSS feed URL and a directory to place the markdown stubs. Usage is:

fetch-rss-feed "https://www.pyopensci.org/python-package-guide/tutorials.rss" "_tutorials"

To support this work, this PR introduces two new dependencies:

  • feedparser: a utility library for fetching and parsing RSS feeds -- this saves us from having to write quite a lot of fetching/parsing logic.
  • unidecode: I use this in a new utility function to easily slugify long title strings. I have a feeling this function will prove useful over time but right now it lets use create filenames from the RSS feeds titles for the Markdown stub files.
  • click: to add arguments and better interfaces to command line scripts

The idea is for this to be just another script to run as a part of the websites automated data updating actions/PRs

Copy link

codecov bot commented Aug 13, 2025

Codecov Report

❌ Patch coverage is 6.66667% with 28 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.84%. Comparing base (760bd63) to head (092a1d5).

Files with missing lines Patch % Lines
src/pyosmeta/parse_rss.py 0.00% 26 Missing ⚠️
src/pyosmeta/utils_clean.py 50.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #301      +/-   ##
==========================================
- Coverage   79.72%   76.84%   -2.89%     
==========================================
  Files          11       12       +1     
  Lines         730      760      +30     
  Branches       95       98       +3     
==========================================
+ Hits          582      584       +2     
- Misses        137      165      +28     
  Partials       11       11              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant