MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / load_tail

Method load_tail

tools/python-3.11.9-amd64/Lib/modulefinder.py:235–248  ·  view source on GitHub ↗
(self, q, tail)

Source from the content-addressed store, hash-verified

233 raise ImportError("No module named " + qname)
234
235 def load_tail(self, q, tail):
236 self.msgin(4, "load_tail", q, tail)
237 m = q
238 while tail:
239 i = tail.find('.')
240 if i < 0: i = len(tail)
241 head, tail = tail[:i], tail[i+1:]
242 mname = "%s.%s" % (m.__name__, head)
243 m = self.import_module(head, mname, m)
244 if not m:
245 self.msgout(4, "raise ImportError: No module named", mname)
246 raise ImportError("No module named " + mname)
247 self.msgout(4, "load_tail ->", m)
248 return m
249
250 def ensure_fromlist(self, m, fromlist, recursive=0):
251 self.msg(4, "ensure_fromlist", m, fromlist, recursive)

Callers 1

import_hookMethod · 0.95

Calls 4

msginMethod · 0.95
import_moduleMethod · 0.95
msgoutMethod · 0.95
findMethod · 0.45

Tested by

no test coverage detected