Feeds: ship full post content in RSS/Atom - #69
Merged
Conversation
RSS feeds shipped truncated summaries only. Pelican's default for RSS is summary-only (RSS_FEED_SUMMARY_ONLY defaults True), and publishconf.py never overrode it, so output/feeds/all.rss.xml carried 150-310 char truncated summaries per item and zero full content. Set RSS_FEED_SUMMARY_ONLY = False in publishconf.py so the RSS feed carries full post HTML in <description>. Note: Pelican does not emit <content:encoded>; it places full content in <description> for RSS, while Atom uses <content>.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The RSS feed shipped summary-only content. Pelican's default for RSS is
summary-only (
RSS_FEED_SUMMARY_ONLYdefaults toTrue), andpublishconf.pynever overrode it. As a resultoutput/feeds/all.rss.xmlcarried short truncated summaries per item (150-310 chars) and zero full
post content, so feed readers only saw a teaser.
Fix
Set
RSS_FEED_SUMMARY_ONLY = Falseinpublishconf.py. Pelican thenplaces the full post HTML in each item's
<description>.Note on
<content:encoded>: Pelican does not emit acontent:encodedelement for RSS. Full content goes into
<description>for RSS (the Atomfeed uses
<content>). So the correct signal that the fix worked is the<description>growing from a truncated summary to full HTML, not thepresence of
content:encoded.Verification
Built with
pelican content -o output -s publishconf.py(Pelican 4.12.0)and compared per-item
<description>payloads:<description>length: 150-310 chars (before) -> 3,563-36,952chars (after), across all 21 items
Guards run locally, all pass:
scripts/check_wellknown_llms.py- 0 issuesscripts/check_em_dashes.py- passscripts/check_descriptions.py- passscripts/check_link_graph.py- 21 posts, 0 issuespython3 -m unittest discover tests- 27 tests OKDeploy builds with
publishconf.py(.github/workflows/deploy.yml), sothe fix reaches production.