From ab4a0154c666a5f7184d3fc4acecf25c875acc15 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Fri, 19 Apr 2024 11:30:12 +0200 Subject: [PATCH] qutebrowser: Fix scihub script to use wikipedia When looking for the most up-to-date link to grab a scihub url we used to use wikiless but now simply directly scrape from wikipedia. Functionality is not changed but should work much faster and more reliably. --- qutebrowser/data/userscripts/doi2scihub | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qutebrowser/data/userscripts/doi2scihub b/qutebrowser/data/userscripts/doi2scihub index 5900eac..b222af9 100755 --- a/qutebrowser/data/userscripts/doi2scihub +++ b/qutebrowser/data/userscripts/doi2scihub @@ -64,7 +64,7 @@ class SciHubLinkParser(html.parser.HTMLParser): self.current = match["url"] if match and match["url"] else None -def get_scihub_url(wiki_page: str = "https://wikiless.org/wiki/Sci-Hub"): +def get_scihub_url(wiki_page: str = "https://en.wikipedia.org/wiki/Sci-Hub"): resp = requests.get(wiki_page) parser = SciHubLinkParser() parser.feed(resp.text)