-
Notifications
You must be signed in to change notification settings - Fork 630
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
请教Failed to execute recipe: list index out of range #702
Comments
在Oracle测试显示403错误(Forbidden),无法调试。 你可以协助定位,在Caibre配置里面添加,然后将错误log记录贴上来。 {
"log_level": "debug"
} |
已经加了这个参数,不过日志好像没有更具体: [recipe_input.py:94] Failed to execute recipe "Laos RFA": list index out of range [plumber.py:394] Failed to execute input plugin: All feeds are empty, aborting. [worker.py:149] There are no new feeds available: admin: [Laos RFA] |
那说明你的版本太老了,可以升级再试,我已经更新了部署脚本,重复升级不会再导致扣费了 |
好的,现在是不是不能再用筛选recipe语言的代码了? |
是的,主要是我不想参数太复杂 |
"[news.py:1960] Failed feed: Laos RFA: Exception Cannot fetch https://www.rfa.org/english/news/laos_news/rss2.xml:403 [news.py:1957->...->news.py:1957->news.py:1957]" |
我记起来了,之前的下标越界问题之前就修正了。 |
官方提供的全文RSS也反爬虫吗?好吧…… |
它这个反爬虫是针对整个网站的,可能技术人员忘了将rss地址单独列为白名单。 |
哎,那没办法了。以前知乎转发器的原理怎么才能用到新版本呢。能否麻烦做个示范的recipe?感觉转发器还是可以解决不少ip地址被封锁的问题 |
feeds = [
("Laos RFA", "http://example.com/?k=xzSlE&t=60&u=https://www.rfa.org/english/news/laos_news/rss2.xml"),
] 只是注意的一点是转发器仅针对反爬虫里面的“封禁IP”,反爬虫还有很多其他多样化的措施。
|
太感谢了!这两天试试。最新的commit右侧显示红色的叉(failure),不知道会不会有影响? |
那个是Github action的执行结果,现在表示项目文档自动更新失败(从*.md自动编译为*.html),和代码没有关系。 至于文档为何更新失败,可能某个编译依赖有变化或系统环境出错之类的,可能下次就好了。 PS:新的部署脚本每次执行都会抓取最新的Calibre Recipe,所以以后calibre的某些recipe有更新,重新执行部署脚本即可同步到你的项目。 |
明白了。刚才部署到了cloudflare,是否URL就是: https://my-worker.subdomain.workers.dev/?k=xzSlE&t=timeout&u=URL 如何判断部署已经成功呢? |
在dashboard里面有 "Visit" 按钮,就是链接,如果出错,可以看dashboard里面的logs 直接访问链接至少会返回
|
刚才又试了一下,应该是可以了。 |
RFA源用了全文rss,推送到Kindle上图片说明的文字会超出Kindle边界,不知道为什么。 另外转发器打开纽约时报的链接是空白,比如:https://www.nytimes.com/2024/08/12/us/politics/us-china-working-group-trade.html |
毕竟我们这个转发器是一个轻量化定制化的工具,不是完整的代理服务器,所以应用场景比较有限, 不管怎么样,区区几十行代码就可以解决我们面临的特定问题,还算一个好工具吧。 |
这两天Calibre好像更新了抓取的代码,看到mobileread作者和网友讨论Science recipe时提到会更新:https://www.mobileread.com/forums/showthread.php?t=362642 昨天还有更新,不知道对KE有无帮助:kovidgoyal/calibre@e8453ed |
Qt是桌面技术,不能在服务器环境使用。 |
经过搜索,发现兼容requests的库niquests已经支持http1.1/2/3,所以之后如果确实有需求,改一行代码就可以了。 |
Science的recipe应该需要支持才能显示图片,Calibre作者这两天刚上传的这个recipe,应该是新版已经解决了这个问题。另外不知道NYT能不能靠此解决 |
好的,等他发布稳定版本,然后你需要哪个recipe在KindleEar里面无法获取,可以提issue,我看是否能解决。 |
用这个NYT的recipe:https://github.com/kovidgoyal/calibre/blob/master/recipes/nytfeeds.recipe 错误提示: [recipe_input.py:89] Failed to execute recipe "NYT News": ValueError No articles downloaded, aborting [recipe_input.py:87->...->news.py:1249->news.py:1562] |
已经修正 |
上传封面图片,20kb左右的jpg格式,总是提示error,不知道为何 |
如果没有具体的原因文字描述,大概率是浏览器的问题 |
原来用的Chrome,确实换成edge就可以了。 今天NYT又有下面的错误,是触发了反爬虫机制吗 Traceback (most recent call last): File "/workspace/application/lib/urlopener.py", line 110, in open_remote_url resp = req_func(url, data=data, headers=headers, timeout=timeout, allow_redirects=True, File "/layers/google.python.pip/pip/lib/python3.10/site-packages/requests/sessions.py", line 602, in get return self.request("GET", url, **kwargs) File "/layers/google.python.pip/pip/lib/python3.10/site-packages/requests/sessions.py", line 589, in request resp = self.send(prep, **send_kwargs) File "/layers/google.python.pip/pip/lib/python3.10/site-packages/requests/sessions.py", line 703, in send r = adapter.send(request, **kwargs) File "/layers/google.python.pip/pip/lib/python3.10/site-packages/requests/adapters.py", line 682, in send raise ConnectionError(err, request=request) requests.exceptions.ConnectionError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response')) |
是的,可以考虑将recipe的simultaneous_downloads设置为1,关闭多线程下载。 |
好的。有的recipe重新抓一次就又可以了,能不能考虑遇到网络问题抓取失败,加个10分钟后自动重新下载的功能,让用户选择是否开启。 主页面的日志,no news提示更详细点,分为两类,一类是真的没有更新的文章,一类是因为网络或页面失败抓取失败。 |
如果使用GAE平台,估计被封锁的概率会大一些,因为很多应用实例会共享一个IP。 |
好的,发现Economist Espresso有时候推送不了,再手动推送一次就会成功 |
[recipe_input.py:94] Failed to execute recipe "Laos RFA": list index out of range
这个是全文RSS,不知道为什么失败。用的是3.0.7版本。
The text was updated successfully, but these errors were encountered: