MCPcopy Index your code
hub / github.com/modelscope/ms-swift / check_link

Function check_link

scripts/utils/test_link_valid.py:10–15  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

8
9
10def check_link(url):
11 try:
12 response = requests.head(url, timeout=5, allow_redirects=True)
13 return response.status_code == 200
14 except requests.RequestException:
15 return False
16
17
18def extract_links_from_md(file_path):

Callers 1

check_links_in_folderFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected