Closed passiomatic closed 9 years ago
To scan the pages looking at the feeds are some very good libraries. https://github.com/ftzeng/feedfinder https://github.com/gosusnp/url2feed https://github.com/kaflesudip/grabfeed https://github.com/papaeye/feedsearcher-py https://github.com/dfm/feedfinder2
Thank you for the links. Coldsweat has already a modified version of the orginal feedfinder. It's very basic since it looks only for <link>
tags, but it works.
The real reason that caused to delay the discovery implementation is that fetcher.fetch_feed is monolitc and quite messy. A refactor is in progress, but there's no ETA yet.
A big +1 on this one, FWIW.
For all the people interested I've commited the feed autodiscovery code on the 0.9.5-wip. Now from the subscribe modal you can enter a feed URL, a web page URL or a domain.com shorthand.
The discovery routine it's pretty basic since it doesn't scan the entire page for potential feeds but only looks for <link>
references - but should cover most of the use cases.
One thing I currently left out but I intend to implement in the near future is a "just subscribe" behavior if just one feed has been found on the page. Actually Coldsweat asks for confirmation even if there's only one available feed.
Anyway you are encouraged to test autodiscovery out.
While adding a feed via web let user to specify site homepage and figure out RSS feed via autodiscovery. This is an usability boost, since sometimes it's difficult to figure out if (and where) a site exposes RSS feeds to syndicate its contents.
Autodiscovery UI is not straightforward to implement, since it has to include corner cases. The three scenarios are:
A. Web page with one feed link
B. Web page with more than one feed link
C. Valid feed link (current implementation)
In all three scenarios above Coldsweat needs to halts the procedure if a broken (or gone) resource is encountered.
References