MCPcopy
hub / github.com/pyload/pyload / get_info

Method get_info

module/plugins/internal/Base.py:43–58  ·  view source on GitHub ↗
(cls, url="", html="")

Source from the content-addressed store, hash-verified

41
42 @classmethod
43 def get_info(cls, url="", html=""):
44 url = fixurl(url, unquote=True)
45 info = {'name': parse_name(url),
46 'hash': {},
47 'pattern': {},
48 'size': 0,
49 'status': 7 if url else 8,
50 'url': replace_patterns(url, cls.URL_REPLACEMENTS)}
51
52 try:
53 info['pattern'] = re.match(cls.__pattern__, url).groupdict()
54
55 except Exception:
56 pass
57
58 return info
59
60 def __init__(self, pyfile):
61 self._init(pyfile.m.core)

Callers 3

grab_infoMethod · 0.95
parse_fileInfoFunction · 0.45
check_name_sizeMethod · 0.45

Calls 4

fixurlFunction · 0.85
parse_nameFunction · 0.85
replace_patternsFunction · 0.85
matchMethod · 0.45

Tested by

no test coverage detected