raise ValueError(f"Parameter command[]='{type(command)}' is not 'str'")
elif command == "":
raise ValueError("Parameter 'command' is empty")
- elif domain.endswith(".arpa"):
- print(f"WARNING: domain='{domain}' is a reversed .arpa domain and should not be used generally.")
- return
elif not validators.domain(domain.split("/")[0]):
raise ValueError(f"domain='{domain}' is not a valid domain")
elif domain.endswith(".arpa"):
elif blacklist.is_blacklisted(instance):
# DEBUG: print("DEBUG: instance is blacklisted:", instance)
continue
-
- # DEBUG: print("DEBUG: Handling instance:", instance)
- if instance.endswith(".arpa"):
- print(f"WARNING: instance='{instance}' is a reversed .arpa domain and should not be used generally.")
- continue
elif instance.find("/profile/") > 0 or instance.find("/users/") > 0:
# DEBUG: print(f"DEBUG: instance='{instance}' is a link to a single user profile - SKIPPED!")
continue
if components.scheme == "" and components.netloc == "":
# DEBUG: print(f"DEBUG: link[href]='{link['href']}' has no scheme and host name in it, prepending from domain='{domain}'")
url = f"https://{domain}{url}"
+ components = urlparse(url)
+
+ if blacklist.is_blacklisted(components.netloc):
+ print(f"WARNING: components.netloc='{components.netloc}' is blacklisted - SKIPPED!")
+ continue
+ elif not validators.domain(components.netloc):
+ print(f"WARNING: components.netloc='{components.netloc}' is not a valid domain - SKIPPED!")
+ continue
# DEBUG: print("DEBUG: Fetching nodeinfo from:", url)
data = network.fetch_api_url(
sofware = tidyup.domain(software)
# DEBUG: print("DEBUG: sofware after tidyup.domain():", software)
- if software in ["akkoma", "rebased"]:
+ if software in ["akkoma", "rebased", "akkounfucked", "ched"]:
# DEBUG: print("DEBUG: Setting pleroma:", domain, software)
software = "pleroma"
elif software in ["hometown", "ecko"]:
# DEBUG: print("DEBUG: Setting mastodon:", domain, software)
software = "mastodon"
- elif software in ["slipfox calckey", "calckey", "groundpolis", "foundkey", "cherrypick", "meisskey"]:
+ elif software in ["slipfox calckey", "calckey", "groundpolis", "foundkey", "cherrypick", "meisskey", "magnetar", "keybump"]:
# DEBUG: print("DEBUG: Setting misskey:", domain, software)
software = "misskey"
elif software == "runtube.re":