Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .venv/lib64
65 changes: 63 additions & 2 deletions sherlock_project/resources/data.json
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,12 @@
"urlMain": "https://atcoder.jp/",
"username_claimed": "ksun48"
},
"Vjudge": {
"errorType": "status_code",
"url": "https://VJudge.net/user/{}",
"urlMain": "https://VJudge.net/",
"username_claimed": "tokitsukaze"
},
"Audiojungle": {
"errorType": "status_code",
"regexCheck": "^[a-zA-Z0-9_]+$",
Expand Down Expand Up @@ -678,6 +684,13 @@
},
"username_claimed": "blue"
},
"Discord.bio": {
"errorType": "message",
"errorMsg": "<title>Server Error (500)</title>",
"url": "https://discords.com/api-v2/bio/details/{}",
"urlMain": "https://discord.bio/",
"username_claimed": "robert"
},
"Discuss.Elastic.co": {
"errorType": "status_code",
"url": "https://discuss.elastic.co/u/{}",
Expand Down Expand Up @@ -1138,6 +1151,12 @@
"urlMain": "https://www.ifttt.com/",
"username_claimed": "blue"
},
"Ifunny": {
"errorType":"status_code",
"url":"https://ifunny.co/user/{}",
"urlMain":"https://ifunny.co/",
"username_claimed":"agua"
},
"IRC-Galleria": {
"errorType": "response_url",
"errorUrl": "https://irc-galleria.net/users/search?username={}",
Expand Down Expand Up @@ -1172,6 +1191,12 @@
"urlProbe": "https://api.imgur.com/account/v1/accounts/{}?client_id=546c25a59c58ad7",
"username_claimed": "blue"
},
"imood": {
"errorType": "status_code",
"url": "https://www.imood.com/users/{}",
"urlMain": "https://www.imood.com/",
"username_claimed": "blue"
},
"Instagram": {
"errorType": "status_code",
"url": "https://instagram.com/{}",
Expand Down Expand Up @@ -1264,7 +1289,9 @@
"kaskus": {
"errorType": "status_code",
"url": "https://www.kaskus.co.id/@{}",
"urlMain": "https://www.kaskus.co.id/",
"urlMain": "https://www.kaskus.co.id",
"urlProbe": "https://www.kaskus.co.id/api/users?username={}",
"request_method": "GET",
"username_claimed": "l0mbart"
},
"Keybase": {
Expand Down Expand Up @@ -1471,6 +1498,15 @@
"urlMain": "https://www.motorradfrage.net/",
"username_claimed": "gutefrage"
},
"MuseScore": {
"errorType": "status_code",
"url": "https://musescore.com/{}",
"urlMain": "https://musescore.com/",
"username_claimed": "arrangeme",
"request_method": "GET"
},


"MyAnimeList": {
"errorType": "status_code",
"url": "https://myanimelist.net/profile/{}",
Expand Down Expand Up @@ -2110,6 +2146,13 @@
"urlMain": "https://robertsspaceindustries.com/",
"username_claimed": "blue"
},
"Status Cafe": {
"errorMsg": "Page Not Found",
"errorType": "message",
"url": "https://status.cafe/users/{}",
"urlMain": "https://status.cafe/",
"username_claimed": "blue"
},
"Steam Community (Group)": {
"errorMsg": "No group could be retrieved for the given URL",
"errorType": "message",
Expand Down Expand Up @@ -2941,5 +2984,23 @@
"urlMain": "https://platzi.com/",
"username_claimed": "freddier",
"request_method": "GET"
},
"Modrinth": {
"errorCode": [404],
"errorType": ["status_code", "message"],
"url": "https://modrinth.com/user/{}",
"urlMain": "https://modrinth.com",
"errorMsg": ["Not Found"],
"username_claimed": "modrinth",
"headers": { "User-Agent": "Mozilla/5.0" }
},
"StackBlitz": {
"urlMain": "https://stackblitz.com",
"url": "https://stackblitz.com/@{}",
"errorType": ["message", "status_code"],
"errorMsg": ["Not Found"],
"errorCode": [404],
"username_claimed": "stackblitz",
"headers": { "User-Agent": "Mozilla/5.0" }
}
}
}
19 changes: 19 additions & 0 deletions tests/test_new_sites_presence.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import json
from pathlib import Path

REQUIRED_FIELDS = {"urlMain", "url", "errorType"}

def load_data():
data_path = Path(__file__).parent.parent / "sherlock_project" / "resources" / "data.json"
with open(data_path, "r", encoding="utf-8") as f:
return json.load(f)

def test_sites_present_with_required_fields():
data = load_data()
for site in ["StackBlitz", "Modrinth"]:
assert site in data, f"{site} entry missing in data.json"
fields = set(data[site].keys())
missing = REQUIRED_FIELDS - fields
assert not missing, f"{site} missing fields: {missing}"

print("All tests passed.")
Loading