diff --git a/parser/main.py b/parser/main.py index f5a2c92..80f2ca8 100644 --- a/parser/main.py +++ b/parser/main.py @@ -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")),