[Feature]: discard soft 404
Feature Summary
if a server provides an *.xml which is actually a 404 html page discard it
What problem does this feature solve?
Version: 2.3.2 Git Commit: Unknown (built outside VCS) Build Date: Unknown (built outside VCS) Go version: go1.26.4 Postgres version: 15.18
Reproduce
- Add the following url: https://manuelcortez.net/2023/08/creating-vm-libvirt-linux-windows/
- Miniflux finds many feeds, e.g. https://manuelcortez.net/atom.xml, which is in reality a 404 html page.
$ curl -si https://manuelcortez.net/atom.xml | head -n 1
HTTP/2 200
$ curl -si https://manuelcortez.net/atom.xml | grep -o 404
404
$ curl -si https://manuelcortez.net/atom.xml | grep -o "rss <version" || echo "Not found"
Not foundThe server is built with HUGO, so the real feed is at https://manuelcortez.net/index.xml, which miniflux finds as well.
It is probably a misconfiguration on the website side, but it would be nice if miniflux would discard them since the content is not an xml/rss.
I'm not sure if miniflux supports html feeds but I was guessing only xml/rss.
Proposed Solution
Check the first bytes of a possible feed to see if it starts with "<rss version" (or similar feed signatures). Something similar to magic bytes for file signature.
Alternatives Considered
No response
Additional Context
No response
Checklist
- I have searched existing issues to ensure this feature hasn't been requested before.
- I understand that feature requests are not guaranteed to be implemented.
- I agree to follow the project's contribution guidelines.
Source: miniflux/v2