Skip to content

Commit 0646063

Browse files
committed
fix: file not found
1 parent 47ab466 commit 0646063

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

devel/site-list.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,11 @@
44
import json
55
import os
66

7+
8+
DATA_REL_URI: str = "sherlock_project/resources/data.json"
9+
710
# Read the data.json file
8-
with open("sherlock_project/resources/data.json", "r", encoding="utf-8") as data_file:
11+
with open(DATA_REL_URI, "r", encoding="utf-8") as data_file:
912
data: dict = json.load(data_file)
1013

1114
# Removes schema-specific keywords for proper processing
@@ -27,7 +30,7 @@
2730
site_file.write(f"1. [{social_network}]({url_main}) {is_nsfw}\n")
2831

2932
# Overwrite the data.json file with sorted data
30-
with open("sherlock/resources/data.json", "w") as data_file:
33+
with open(DATA_REL_URI, "w") as data_file:
3134
sorted_data = json.dumps(data, indent=2, sort_keys=True)
3235
data_file.write(sorted_data)
3336
data_file.write("\n")

0 commit comments

Comments
 (0)