MCPcopy Create free account
hub / github.com/Kaggle/docker-python / KaggleFileResolver

Class KaggleFileResolver

patches/kaggle_module_resolver.py:16–22  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

14 return long_url_pattern.match(handle) != None or short_url_pattern.match(handle) != None
15
16class KaggleFileResolver(resolver.HttpResolverBase):
17 def is_supported(self, handle):
18 return _is_on_kaggle_notebook() and _is_kaggle_handle(handle)
19
20 def __call__(self, handle):
21 m = long_url_pattern.match(handle) or short_url_pattern.match(handle)
22 return kagglehub.model_download(f"{m.group('owner')}/{m.group('model')}/{m.group('framework').lower()}/{m.group('variation')}/{m.group('version')}")

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected