1
0
mirror of synced 2024-06-28 23:35:24 +08:00

fix script

This commit is contained in:
xueweihan 2024-06-12 17:30:24 +08:00
parent 7f8da6f955
commit d659d63f75

View File

@ -140,20 +140,20 @@ def main(verbose=False) -> None:
print('Start script.')
session = HTMLSession()
content = ""
# content_list = get_json(session)
# for item in content_list:
# content += item[0].ljust(30) + item[1] + "\n"
content_list = []
for index, github_url in enumerate(GITHUB_URLS):
try:
ip = get_ip(session, github_url)
content_list = get_json(session)
for item in content_list:
content += item[0].ljust(30) + item[1] + "\n"
# content_list = []
# for index, github_url in enumerate(GITHUB_URLS):
# try:
# ip = get_ip(session, github_url)
content += ip.ljust(30) + github_url + "\n"
content_list.append((ip, github_url,))
except Exception:
continue
if verbose:
print(f'process url: {index + 1}/{len(GITHUB_URLS)}')
# content += ip.ljust(30) + github_url + "\n"
# content_list.append((ip, github_url,))
# except Exception:
# continue
# if verbose:
# print(f'process url: {index + 1}/{len(GITHUB_URLS)}')
if not content:
return