如何解决为什么我的 atom 提要无法加载到我在 Feedly 中的站点的链接?
我正在使用 FeedGenerator (https://feedgen.kiesow.be/) 在 Flask 中生成我的 atom 提要,在我看来它是正确的。当我在 Feedly 中添加提要时,没有链接,“直接在网站中打开”会转到 Feedly 404 页面。这是我在生成提要的烧瓶中的路线:
def RSS():
RSS_url = 'https://www.example.com/RSS'
base_url = 'https://www.example.com'
fg = FeedGenerator()
fg.id(RSS_url)
fg.title('MysSite Feed')
fg.description('My site description')
fg.link(href='https://www.example.com')
for article in get_RSS_posts():
fe = fg.add_entry()
fe.title(article.title)
fe.link(href=base_url+'/post/'+article.slug)
fe.content(article.body)
fe.summary(article.short_desc)
fe.id(base_url+'/post/'+article.slug)
fe.author(name=article.author.username)
fe.pubDate(article.timestamp.astimezone(timezone('America/Chicago')))
return Response(fg.atom_str(pretty=True),mimetype="application/atom+xml; charset=utf-8")```
My generated Feed when viewed in Chrome:
<?xml version='1.0' encoding='UTF-8'?>
<Feed xmlns="http://www.w3.org/2005/Atom">
<id>https://www.example.com/RSS/devops</id>
<title>Example - devops Feed</title>
<updated>2021-04-08T21:13:58.427520+00:00</updated>
<link href="https://www.example.com"/>
<generator uri="https://lkiesow.github.io/python-Feedgen" version="0.9.0">python-Feedgen</generator>
<subtitle>Example is your source for devops posts.</subtitle>
<entry>
<id>https://www.example.com/post/uptime-robot</id>
<title>Uptime Robot</title>
<updated>2021-04-08T21:13:58.445502+00:00</updated>
<author>
<name>ExampleAdmin</name>
</author>
<content><h4>I Needed A Monitor To Check Uptime</h4>
<p>I needed a website monitoring service for Example that let me kNow if it went down. There are a many options but I only found one that met all of my needs:</p>
<ul>
<li><strong>Free -</strong> I'm running this site on a budget so I need a service that's reliable but doesn't cost me anything</li>
<li><strong>SMS and Email messaging -</strong> I need a service that emails and texts me if my site goes offline</li>
<li><strong>Easy to use -</strong> I need something simple that I can just set and forget</li>
<li><strong>Allows for multiple monitors -</strong> 1 just won't cut it</li>
</ul>
<h4>Verdict</h4>
<p><a href="https://uptimerobot.com/" target="_blank">Uptime Robot</a> met all of my needs and did I mention that they have a free option? If you need a bit more they have a cheap monthly plan too. Currently,the free plan is working for me.</p>
<p>Uptime Robot gets a Pass from me! </p>
<p><b class="icon solid fa-fire iof-fire">&nbsp;</b></p></content>
<link href="https://www.example.com/post/uptime-robot" rel="alternate"/>
<summary><p>Need a tool to monitor your website's uptime? See our top recommendation!</p></summary>
<published>2021-02-18T16:57:22-06:00</published>
</entry>
</Feed>
This is a Feedly link on my website that allows following: https://Feedly.com/i/subscription/Feed%2Fhttps%3A%2F%2Fwww.example.com%2F/RSS/devops
When I click the Feedly link,my site shows up and allows me to follow it. The problem is that none of the news articles have links that will load on my website. If I turn on the "Open in website directly" and click a link,I get a Feedly 404 page.
Does anyone kNow what the problem is? Thanks!
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。