Skip to content

Commit

Permalink
redlib: try to fix non-clearnet
Browse files Browse the repository at this point in the history
  • Loading branch information
NoPlagiarism committed Oct 29, 2024
1 parent 3d30082 commit 6dd9b14
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions parser/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -549,8 +549,8 @@ def get_clearnet_base(path):
JSONUsingCallableInstance(relative_filepath_without_ext=Network.ONION, url="https://raw.githubusercontent.com/libreddit/libreddit-instances/master/instances.json", json_handle=lambda raw: tuple(map(get_domain_from_url, tuple(filter(lambda url: url is not None, [x.get("onion") for x in raw["instances"]]))))))),
InstancesGroupData(name="redlib", home_url="https://github.com/redlib-org/redlib#readme", relative_filepath_without_ext="reddit/redlib",
instances=(JSONUsingCallableInstance(relative_filepath_without_ext=Network.CLEARNET, url="https://raw.githubusercontent.com/redlib-org/redlib-instances/main/instances.json", json_handle=lambda raw: tuple(map(get_domain_from_url, [x["url"] for x in raw["instances"] if "url" in x]))),
JSONUsingCallableInstance(relative_filepath_without_ext=Network.ONION, url="https://raw.githubusercontent.com/redlib-org/redlib-instances/main/instances.json", json_handle=lambda raw: tuple(map(get_domain_from_url, [x["onion"] for x in raw["instances"] if "onion" in x]))),
JSONUsingCallableInstance(relative_filepath_without_ext=Network.I2P, url="https://raw.githubusercontent.com/redlib-org/redlib-instances/main/instances.json", json_handle=lambda raw: tuple(map(get_domain_from_url, [x["i2p"] for x in raw["instances"] if "i2p" in x]))))),
GetDomainsFromHeadersInstance(relative_filepath_without_ext=Network.ONION, header=MirrorHeaders.ONION, main=get_clearnet_base("reddit/redlib")),
GetDomainsFromHeadersInstance(relative_filepath_without_ext=Network.I2P, header=MirrorHeaders.I2P, main=get_clearnet_base("reddit/redlib")))),
InstancesGroupData(name="WikiLess", home_url="https://gitea.slowb.ro/ticoombs/Wikiless#wikiless", relative_filepath_without_ext="wikipedia/wikiless",
instances=(JustFromUrlInstance(relative_filepath_without_ext=Network.CLEARNET, url="https://raw.githubusercontent.com/NoPlagiarism/frontend-instances-custom/master/wikiless/clearnet.txt"),
GetDomainsFromHeadersInstance(relative_filepath_without_ext=Network.ONION, header=MirrorHeaders.ONION, main=get_clearnet_base("wikipedia/wikiless")),
Expand Down

0 comments on commit 6dd9b14

Please sign in to comment.