MCPcopy
hub / github.com/marimo-team/marimo / is_github_src

Function is_github_src

marimo/_cli/files/file_path.py:24–32  ·  view source on GitHub ↗
(url: str, ext: str)

Source from the content-addressed store, hash-verified

22
23
24def is_github_src(url: str, ext: str) -> bool:
25 if not is_url(url):
26 return False
27
28 hostname = urllib.parse.urlparse(url).hostname
29 if hostname != "github.com" and hostname != "raw.githubusercontent.com":
30 return False
31 path: str = urllib.parse.urlparse(url).path
32 return path.endswith(ext)
33
34
35def get_github_src_url(url: str) -> str:

Callers 3

load_external_fileFunction · 0.90
can_readMethod · 0.85

Calls 1

is_urlFunction · 0.90

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…