-
Notifications
You must be signed in to change notification settings - Fork 358
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
fix http(s) socks5 nyaa search #548
Conversation
…nd trailing whitespace
fix: 使用反代时 RSS 图标路径错误
fix: 🐛 通知的内容包含无意义的前导和尾随空格
chore: fix typo in experimental docs
fix http https
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -21,8 +21,11 @@ | |||
|
|||
class SearchTorrent(RequestContent, RSSAnalyser): | |||
def search_torrents(self, rss_item: RSSItem) -> list[Torrent]: | |||
torrents = self.get_torrents(rss_item.url) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里改的毫无意义,增加了实体内存占用。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
改了才能搜索走socks5
if not len(soup.findall("./channel/item/enclosure")): | ||
for item in soup.findall("./channel/item"): | ||
torrent_titles.append(item.find("title").text) | ||
torrent_urls.append(item.find("link").text) | ||
torrent_homepage.append(item.find("guid").text) | ||
else: | ||
for item in soup.findall("./channel/item"): | ||
torrent_titles.append(item.find("title").text) | ||
torrent_urls.append(item.find("enclosure").attrib["url"]) | ||
torrent_homepage.append(item.find("link").text) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这段代码说实话看着有点冗余,其实在循环的时候是不是只需要对可能会变动的 torrent_urls
和 torrent_homepage
做条件判断就可以了?
1.修复http(s) 带密码验证连接
2.修复socks5不能搜索
3.修复nyaa不能搜索