sphinx-doc/sphinx

Feed generation

shimizukawa opened this issue · 10 comments

Add some directive that automatically generates an RSS feed for its items.


From Éric Araujo on 2010-10-29 00:13:42+00:00

I don’t get what the entries of the feed would be.

From Georg Brandl on 2010-10-29 05:43:56+00:00

Basically, the content of the directive, formatted as some list. But it's all a bit vague, and that's why this hasn't been implemented yet :)

From Anonymous on 2010-10-29 07:13:53+00:00

I think it should just provide the list of the new pages in a reverse chronological order (most recent at the top), with the full content of the article as description.

Personnaly, I do not like when content is limited in a feed.

From glenfant on 2010-11-12 12:31:05+00:00

Hmmm

Adding a new markup for this...
{{{
.. syndication-feed:: [a title or keep title of the page]
:description: An optional description of the feed
}}}
This markup should be unique in a file.

In "conf.py"
{{{
feed_format = None # default
feed_format = "rss"
feed_format = "atom"

Think we should know from the conf the publication URL to build this static feed (?)

}}}

This would require some changes in templates too. So it would not be that easy to make this in an extension IMHO. Would love to have time to make such an extension.

Now, we have three extensions to generate RSS feed.

I think main purpose of this issue is resolved by them.
So I close this issue.

Thans,

Neither extension has been ported to Python 3, so if you want to use Sphinx with Python 3, you are out of luck. One can move to Tinkerer, though that seems like a major change to me.

  • I have tried to port sphinx-contrib/feed to Python 3, but the feed that is generated does not seem to be a valid RSS feed. At least Akregator and W3C do not like it.

  • sphinxfeed depends on feedformatter and that is not available for Python 3 either.

So either I downgrade to Python 2 again for Sphinx, switch to one of the million other static site generators, or just forget about the RSS feed. All options are not quite satisfying.

For those that find this issue on Google and think RSS feed blogs / news / release lists are not supported by Sphinx, you should know that the sphinxcontrib-newsfeed extension mentioned above has supported Python 3 since 2013 and works perfectly. There has not been a release since 2015, but the Sphinx API is stable and the extension still works as it is supposed to, so there is probably no need for any changes at the moment.

An example from one of my packages: News-blog https://trlandet.bitbucket.io/ocellaris/blog/ has RSS feed https://trlandet.bitbucket.io/ocellaris/index.rss

PS: this functionality is so useful and stable that it could be promoted a bit more, by inclusion in the main repo or by a link in the documentation perhaps?

As sphinxcontrib-newsfeed is loading 3rd party scripts from disqus.com, I'd say it shouldn't be part of the sphinx core--IMHO 3rd party integration extensions are too volatile for this. However, I suggest we can move the repo to the sphinx-contrib organization, if the Sphinx maintainers and the sphinxcontrib-newsfeed author(@xitology) agree. This would add visibility to the extension and makes it easier to maintain in case the original author does not have time. I think we can also link to the extension from the FAQ, if it is moved to the sphinx-contrib organization.

AFAIK, sphinx-contrib organization is mere a collection of repositories. There are no special rules. So nothing will be changed even if moved. Sphinx-core team does not have any permissions for repo, and also can't release a new version.

BTW, we can add a hyperlink to official docs without moving. +1 for adding!

I now ported my fork of sphinxfeed to Python 3: https://github.com/lsaffre/sphinxfeed