Closed mbologna closed 4 months ago
Hi @mbologna ! Sadly I do not have a solution for this.
The feedreader will likely just fetch the favicon from the origin of the feed, which in this case will always be pipes.digital itself. If your feedreader instead would use an element from the feed itself, then we could manipulate the feed - but the image element is to my knowledge always ignored. Probably because those don't have to be a square.
Depending on the reader you use there might be an option to change the used icon. But in my reader at least, Fresh RSS, I saw no such option.
I think that the solution would be to manipulate the feed produced by pipes.digital and declare the favicon in the feed like this:
<link rel="shortcut icon" href="website_source/favicon.ico" type="image/x-icon" />
Oh, that'd be interesting. Could you point me to a feed that uses this solution?
Oh, that'd be interesting. Could you point me to a feed that uses this solution?
I have done an experiment but it does not work, as the browser will look in /favicon.ico
nevertheless.
All in all I think, that this limitation cannot be overcame, unfortunately.
Ha, good idea to just put up a modified textfile. Sad that it did not work.
Should we close here, and re-open if we stumble over a solution?
I just found out that another application (RSS Filter) manipulates a feed while keeps the original favicon/logo. Example: if you add https://rssfilter-a7aj2utffa-uc.a.run.app/feed?title_allow=Google&url=https%3A%2F%2Fwww.arstechnica.com%2Ffeed%2F to your feed reader, it shows the original site logo.
I believe that the feed built by pipes.digital is missing the <image>
:
<channel>
<image>
<url>
https://cdn.arstechnica.net/wp-content/uploads/2016/10/cropped-ars-logo-512_480-32x32.png</url>
<title>Ars Technica</title>
<link>https://arstechnica.com</link>
<width>32</width>
<height>32</height>
</image>
(in case of combined feed, just replicate the first feed's <image>
. What do you think?
A little bit confusing, because that seems to be exactly the image element I claimed would be ignored. But I can confirm that the feed you linked to does have an image element, I mean, icon in my feed reader. You could now extract that element and insert it into a feed by pipes ;)
I will check whether pipes' RSS feed generation code can keep the image element of the channel.
Let's start maybe indeed with a solution to do this with Pipes? Have a look:
As a last step of your pipe, take the original feed and extract the image element (path: /rss/channel/image
, attribute: OuterXml
) and insert this into your feed with the insert block (at /rss/channel
).
Because on a first look, it seems like the feed parser library Pipes use drops the image element completely, so this would be linked to the bigger question of how to not parse the data like this when going from block to block, or at least would need a parser extension.
As a last step of your pipe, take the original feed and extract the image element (path:
/rss/channel/image
, attribute:OuterXml
) and insert this into your feed with the insert block (at/rss/channel
).
I added the workaround for the <image>
tag:
but it returns a HTTP 500: https://www.pipes.digital/feedpreview/pqwY2wNB
Because on a first look, it seems like the feed parser library Pipes use drops the image element completely, so this would be linked to the bigger question of how to not parse the data like this when going from block to block, or at least would need a parser extension.
What parser library is Pipes using?
Hm, I went into the logs and don't understand the error. It's the insert block that claims it sees no element?
Try it from here: https://www.pipes.digital/pipe/POdv0L9D. That pipe works for me, it should be possible to extend it feed by feed. Maybe we can pinpoint like this where the error is.
What parser library is Pipes using?
Pipes is running the feeds through https://github.com/rubycocos/feedparser/tree/master/feedparser for normalization
Hm, I went into the logs and don't understand the error. It's the insert block that claims it sees no element?
I don't see any error from the UI either.
Try it from here: pipes.digital/pipe/POdv0L9D. That pipe works for me, it should be possible to extend it feed by feed. Maybe we can pinpoint like this where the error is.
I added the feed in Feedly but the feed icon is not shown. Maybe because the <image>
tag is towards the end?
I added the feed in Feedly but the feed icon is not shown. Maybe because the
tag is towards the end?
That shouldn't matter, I would expect the feed reader to parse the whole file and the position doesn't matter in XML. But you are right! It doesn't work also in FreshRSS. And right: The position does not matter, I uploaded the rss file and changed it to the top, no change.
Did we miss something else?
Seems like Ars' feed is XML not valid right now. Can you please retry with something else, like https://openrss.org/www.theverge.com ?
It's the link element!
The feed has this in it:
?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="/www.theverge.com/.xsl"?>
<rss version="2.0">
<channel>
...
<link><![CDATA[https://arstechnica.com/]]></link>
The image element is ignored, but depending on the link element the favicon of the linked site gets selected. At least in FreshRSS. It's a bit hard to test because changing the element in an already subscribed file did not change the favicon for me, but creating a new feed with changed links works as expected. I set in https://pipes.digital
and it switched.
Can you confirm that?
Changing the link element of the channel should be something we can also do with an insert block :)
Can you confirm that?
I tried with the feed you linked above (https://www.pipes.digital/feed/POdv0L9D?) but it still show the pipes.digital
icon
Did you try it directly with that feed, or did you modify the output to change the link element? The needed modification is not done there yet
I did the following:
and I can see the <link>
correctly populate in the feed https://www.pipes.digital/feed/pqwY2wNB?
I re-added the feed to Feedly but I still see pipes.digital's favicon
It's not quite correct I think, because this will set a second link element. Instead replace the content of the old one:
I changed it in https://www.pipes.digital/pipe/POdv0L9D and it worked for me! :)
I changed it in pipes.digital/pipe/POdv0L9D and it worked for me! :)
I tried this one in Feedly and I still see pipes.digital's favicon. I guess Feedly uses a different criteria?
Hm. They might use the atom10:link
element instead. Or the old icon is cached for that feed. Maybe try it once more in a different pipe?
I duplicated the feed above and I can confirm it is working, so likely a caching issue on Feedly. Thanks a lot for the shared debugging and the solution, it was fun!
Fun indeed :) And we solved it!
The logic to set the pipes site by default is not bad by itself, so I think we can stick to the custom solution we identified here?
Yes this is a workaround, at least, until the dependency library can be instructed to fetch the <link>
.
My feed reader show the favicon of pipes.digital, is there a way to build a feed and to specify a custom favicon?