bugged
stringlengths
4
228k
fixed
stringlengths
0
96.3M
__index_level_0__
int64
0
481k
def ignorableWhitespace(self, chars, start, end): self._cont_handler.ignorableWhitespace(chars, start, end)
def ignorableWhitespace(self, chars, start, end): self._cont_handler.ignorableWhitespace(chars, start, end)
13,000
def h(j=1, a=2, h=3): print j, a, h
def h(j=1, a=2, h=3): print j, a, h
13,001
def maybe_mutate(): if not mutate: return if random.random() < 0.5: return if random.random() < 0.5: target, keys = dict1, dict1keys else: target, keys = dict2, dict2keys if keys: i = random.randrange(len(keys)) key = keys[i] del target[key] # CAUTION: don't use keys.remove(key) here. Or do <wink>. The # point is th...
def maybe_mutate(): if not mutate: return if random.random() < 0.5: return if random.random() < 0.5: target, keys = dict1, dict1keys else: target, keys = dict2, dict2keys if random.random() < 0.2: mutate = 0 while 1: newkey = Horrid(random.randrange(100)) if newkey not in target: break target[newkey] = Horrid(random....
13,002
def _norm_version(version,build=''): """ Normalize the version and build strings and return a single vesion string using the format major.minor.build (or patchlevel). """ l = string.split(version,'.') if build: l.append(build) try: ints = map(int,l) except ValueError: strings = l else: strings = map(str,ints) version ...
def _norm_version(version,build=''): """ Normalize the version and build strings and return a single version string using the format major.minor.build (or patchlevel). """ l = string.split(version,'.') if build: l.append(build) try: ints = map(int,l) except ValueError: strings = l else: strings = map(str,ints) version...
13,003
def goahead(self, end): rawdata = self.rawdata i = 0 n = len(rawdata) while i < n: if i > 0: self.__at_start = 0 if self.nomoretags: data = rawdata[i:n] self.handle_data(data) self.lineno = self.lineno + string.count(data, '\n') i = n break res = interesting.search(rawdata, i) if res: j = res.start(0) else: j = n if i ...
def goahead(self, end): rawdata = self.rawdata i = 0 n = len(rawdata) while i < n: if i > 0: self.__at_start = 0 if self.nomoretags: data = rawdata[i:n] self.handle_data(data) self.lineno = self.lineno + string.count(data, '\n') i = n break res = interesting.search(rawdata, i) if res: j = res.start(0) else: j = n if i ...
13,004
def __del__(self): """Call the "close()" method in case the user forgot.""" if self.fp and not self._filePassed: self.fp.close() self.fp = None
def __del__(self): """Call the "close()" method in case the user forgot.""" if self.fp and not self._filePassed: self.fp.close() self.fp = None
13,005
def compile(file, cfile=None, dfile=None, doraise=False): """Byte-compile one Python source file to Python bytecode. Arguments: file: source filename cfile: target filename; defaults to source with 'c' or 'o' appended ('c' normally, 'o' in optimizing mode, giving .pyc or .pyo) dfile: purported filename; defaul...
def compile(file, cfile=None, dfile=None, doraise=False): """Byte-compile one Python source file to Python bytecode. Arguments: file: source filename cfile: target filename; defaults to source with 'c' or 'o' appended ('c' normally, 'o' in optimizing mode, giving .pyc or .pyo) dfile: purported filename; defaul...
13,006
def test_guess_all_types(self): eq = self.assertEqual # First try strict all = self.db.guess_all_extensions('text/plain', strict=True) all.sort() eq(all, ['.bat', '.c', '.h', '.ksh', '.pl', '.txt']) # And now non-strict all = self.db.guess_all_extensions('image/jpg', strict=False) all.sort() eq(all, ['.jpg']) # And now...
def test_guess_all_types(self): eq = self.assertEqual # First try strictunless = self.failUnless all = Set(self.db.guess_all_extensions('text/plain', strict=True)) unless(all >= Set(['.bat', '.c', '.h', '.ksh', '.pl', '.txt'])) # And now non-strict all = self.db.guess_all_extensions('image/jpg', strict=False) all.so...
13,007
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
13,008
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
13,009
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
13,010
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
def detect_tkinter(self, inc_dirs, lib_dirs): # The _tkinter module.
13,011
def lock(self, how, *args):
def lock(self, how, *args):
13,012
def test_getstatus(self): # This pattern should match 'ls -ld /.' on any posix # system, however perversely configured. pat = r'''d......... # It is a directory. \s+\d+ # It has some number of links. \s+\w+\s+\w+ # It has a user and group, which may # be named anything. \s+\d+ # It has a size. [^/]* ...
def test_getstatus(self): # This pattern should match 'ls -ld /.' on any posix # system, however perversely configured. pat = r'''d......... # It is a directory. \s+\d+ ...
13,013
def test_getstatus(self): # This pattern should match 'ls -ld /.' on any posix # system, however perversely configured. pat = r'''d......... # It is a directory. \s+\d+ # It has some number of links. \s+\w+\s+\w+ # It has a user and group, which may # be named anything. \s+\d+ # It has a size. [^/]* ...
def test_getstatus(self): # This pattern should match 'ls -ld /.' on any posix # system, however perversely configured. pat = r'''d......... # It is a directory. \s+\d+ # It has some number of links. \s+\w+\s+\w+ # It has a user and group, which may # be named anything. \s+\d+ # It has a size. [^/]* ...
13,014
def find_module(self, name, path): if name in self.excludes: self.msgout(3, "find_module -> Excluded") raise ImportError, name
deffind_module(self,name,path):ifnameinself.excludes:self.msgout(3,"find_module->Excluded")raiseImportError,name
13,015
def find_module(self, name, path): if name in self.excludes: self.msgout(3, "find_module -> Excluded") raise ImportError, name
def find_module(self, name, path): if name in self.excludes: self.msgout(3, "find_module -> Excluded") raise ImportError, name
13,016
def fixupOrderForward(self, blocks, default_next): """Make sure all JUMP_FORWARDs jump forward""" index = {} chains = [] cur = [] for b in blocks: index[b] = len(chains) cur.append(b) if b.next and b.next[0] == default_next: chains.append(cur) cur = [] chains.append(cur)
deffixupOrderForward(self,blocks,default_next):"""MakesureallJUMP_FORWARDsjumpforward"""index={}chains=[]cur=[]forbinblocks:index[b]=len(chains)cur.append(b)ifb.nextandb.next[0]==default_next:chains.append(cur)cur=[]chains.append(cur)
13,017
def flattenGraph(self): """Arrange the blocks in order and resolve jumps""" assert self.stage == RAW self.insts = insts = [] pc = 0 begin = {} end = {} for b in self.getBlocksInOrder(): begin[b] = pc for inst in b.getInstructions(): insts.append(inst) if len(inst) == 1: pc = pc + 1 else: # arg takes 2 bytes pc = pc + 3...
def flattenGraph(self): """Arrange the blocks in order and resolve jumps""" assert self.stage == RAW self.insts = insts = [] pc = 0 begin = {} end = {} for b in self.getBlocksInOrder(): begin[b] = pc for inst in b.getInstructions(): insts.append(inst) if len(inst) == 1: pc = pc + 1 else: # arg takes 2 bytes pc = pc + 3...
13,018
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
def findDepth(self, insts, debug=0): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta...
13,019
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] if debug: print i, delta = self.effect.get(opname, None) if delta is not None: depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self.patterns: if opname[:len(pat)] == pat: delta =...
13,020
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: depth = depth + delta else: # now check patterns for pat, pat_delta in self.patterns: if opname[:len(pat)] == pat: delta = pat_delta depth = depth + del...
13,021
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
13,022
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
def findDepth(self, insts): depth = 0 maxDepth = 0 for i in insts: opname = i[0] delta = self.effect.get(opname, 0) if delta > 1: depth = depth + delta elif delta < 0: if depth > maxDepth: maxDepth = depth depth = depth + delta else: if depth > maxDepth: maxDepth = depth # now check patterns for pat, pat_delta in self....
13,023
def CALL_FUNCTION(self, argc): hi, lo = divmod(argc, 256) return lo + hi * 2
def CALL_FUNCTION(self, argc): hi, lo = divmod(argc, 256) return lo + hi * 2
13,024
def CALL_FUNCTION_VAR(self, argc): return self.CALL_FUNCTION(argc)+1
def CALL_FUNCTION_VAR(self, argc): return self.CALL_FUNCTION(argc)+1
13,025
def CALL_FUNCTION_KW(self, argc): return self.CALL_FUNCTION(argc)+1
def CALL_FUNCTION_KW(self, argc): return self.CALL_FUNCTION(argc)+1
13,026
def CALL_FUNCTION_VAR_KW(self, argc): return self.CALL_FUNCTION(argc)+2
def CALL_FUNCTION_VAR_KW(self, argc): return self.CALL_FUNCTION(argc)+2
13,027
def read_lines_to_outerboundary(self):
def read_lines_to_outerboundary(self):
13,028
def list_directory(self, path): """Helper to produce a directory listing (absent index.html).
def list_directory(self, path): """Helper to produce a directory listing (absent index.html).
13,029
def list_directory(self, path): """Helper to produce a directory listing (absent index.html).
def list_directory(self, path): """Helper to produce a directory listing (absent index.html).
13,030
def external_entity_ref(self, context, base, sysid, pubid): if not self._external_ges: return 1 source = self._ent_handler.resolveEntity(pubid, sysid) source = saxutils.prepare_input_source(source, self._source.getSystemId() or "")
def external_entity_ref(self, context, base, sysid, pubid): if not self._external_ges: return 1 source = self._ent_handler.resolveEntity(pubid, sysid) source = saxutils.prepare_input_source(source, self._source.getSystemId() or "")
13,031
def __hash__(self, *args): print "__hash__:", args return id(self)
def __hash__(self, *args): print "__hash__:", args return id(self)
13,032
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> import doc...
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> import doctest >>> old = doctest._unittest_reportflags >>> doctest.set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_F...
13,033
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> import doc...
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> doctest._u...
13,034
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> import doc...
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> import doc...
13,035
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> import doc...
def set_unittest_reportflags(flags): """Sets the unittest option flags. The old flag is returned so that a runner could restore the old value if it wished to: >>> old = _unittest_reportflags >>> set_unittest_reportflags(REPORT_NDIFF | ... REPORT_ONLY_FIRST_FAILURE) == old True >>> import doc...
13,036
def test_timeout(): test_support.requires('network') if test_support.verbose: print "test_timeout ..." # A service which issues a welcome banner (without need to write # anything). # XXX ("gmail.org", 995) has been unreliable so far, from time to time # XXX non-responsive for hours on end (& across all buildbot slave...
def test_timeout(): test_support.requires('network') if test_support.verbose: print "test_timeout ..." # A service which issues a welcome banner (without need to write # anything). # XXX ("gmail.org", 995) has been unreliable so far, from time to time # XXX non-responsive for hours on end (& across all buildbot slave...
13,037
def test_timeout(): test_support.requires('network') if test_support.verbose: print "test_timeout ..." # A service which issues a welcome banner (without need to write # anything). # XXX ("gmail.org", 995) has been unreliable so far, from time to time # XXX non-responsive for hours on end (& across all buildbot slave...
def test_timeout(): test_support.requires('network') if test_support.verbose: print "test_timeout ..." # A service which issues a welcome banner (without need to write # anything). # XXX ("gmail.org", 995) has been unreliable so far, from time to time # XXX non-responsive for hours on end (& across all buildbot slave...
13,038
def __init__(self, parent, title = None):
def __init__(self, parent, title = None):
13,039
def user_line(self, frame):
def user_line(self, frame):
13,040
def user_line(self, frame):
def user_line(self, frame):
13,041
def user_line(self, frame):
def user_line(self, frame):
13,042
def poll(self): if not self.async: raise error, 'Can only call poll() in async mode' if not self.busy_cmd: return if self.testready(): if self.cb: apply(self.cb, self.cb_arg)
def poll(self): if not self.async: raise error, 'Can only call poll() in async mode' if not self.busy_cmd: return if self.testready(): if self.cb: apply(self.cb, self.cb_arg)
13,043
def split(s): if ':' not in s: return '', s colon = 0 for i in range(len(s)): if s[i] == ':': colon = i+1 return s[:colon-1], s[colon:]
def split(s): if ':' not in s: return '', s colon = 0 for i in range(len(s)): if s[i] == ':': colon = i+1 path, file = s[:colon-1], s[colon:] if path and not ':' in path: path = path + ':' return path, file
13,044
def set(self, *args): """Set the fractional values of the slider position (upper and lower ends as value between 0 and 1).""" self.tk.call((self._w, 'set') + args)
defset(self,*args):"""Setthefractionalvaluesofthesliderposition(upperandlowerendsasvaluebetween0and1)."""self.tk.call((self._w,'set')+args)
13,045
def import_from(self, nodelist): # import_from: 'from' dotted_name 'import' ('*' | # '(' import_as_names ')' | import_as_names) assert nodelist[0][1] == 'from' assert nodelist[1][0] == symbol.dotted_name assert nodelist[2][1] == 'import' fromname = self.com_dotted_name(nodelist[1]) if nodelist[3][0] == token.STAR: #...
def import_from(self, nodelist): # import_from: 'from' dotted_name 'import' ('*' | # '(' import_as_names ')' | import_as_names) assert nodelist[0][1] == 'from' assert nodelist[1][0] == symbol.dotted_name assert nodelist[2][1] == 'import' fromname = self.com_dotted_name(nodelist[1]) if nodelist[3][0] == token.STAR: #...
13,046
def _deepcopy_atomic(x, memo): return x
def _deepcopy_atomic(x, memo): return x
13,047
def ignored(self, file): if os.path.isdir(file): return True for pat in self.IgnoreList: if fnmatch.fnmatch(file, pat): return True return Falso
def ignored(self, file): if os.path.isdir(file): return True for pat in self.IgnoreList: if fnmatch.fnmatch(file, pat): return True return Falso
13,048
def fcmp(x, y): # fuzzy comparison function if type(x) == type(0.0) or type(y) == type(0.0): try: x, y = coerce(x, y) fuzz = (abs(x) + abs(y)) * FUZZ if abs(x-y) <= fuzz: return 0 except: pass elif type(x) == type(y) and type(x) in (type(()), type([])): for i in range(min(len(x), len(y))): outcome = fcmp(x[i], y[i]) if...
def fcmp(x, y): # fuzzy comparison function if type(x) == type(0.0) or type(y) == type(0.0): try: x, y = coerce(x, y) fuzz = (abs(x) + abs(y)) * FUZZ if abs(x-y) <= fuzz: return 0 except: pass elif type(x) == type(y) and type(x) in (type(()), type([])): for i in range(min(len(x), len(y))): outcome = fcmp(x[i], y[i]) if...
13,049
def extract(s): res = decoder.match(s) if res is None: raise NotANumber, s sign, intpart, fraction, exppart = res.group(1,2,3,4) if sign == '+': sign = '' if fraction: fraction = fraction[1:] if exppart: expo = eval(exppart[1:]) else: expo = 0 return sign, intpart, fraction, expo
def extract(s): res = decoder.match(s) if res is None: raise NotANumber, s sign, intpart, fraction, exppart = res.group(1,2,3,4) if sign == '+': sign = '' if fraction: fraction = fraction[1:] if exppart: expo = int(exppart[1:]) else: expo = 0 return sign, intpart, fraction, expo
13,050
def preprocess (self, source, output_file=None, macros=None, include_dirs=None, extra_preargs=None, extra_postargs=None):
def preprocess (self, source, output_file=None, macros=None, include_dirs=None, extra_preargs=None, extra_postargs=None):
13,051
def preprocess (self, source, output_file=None, macros=None, include_dirs=None, extra_preargs=None, extra_postargs=None):
def preprocess (self, source, output_file=None, macros=None, include_dirs=None, extra_preargs=None, extra_postargs=None):
13,052
def encode(self, input, final=False): return codecs.mbcs_encode(input,self.errors)[0]
def encode(self, input, final=False): return codecs.mbcs_encode(input,self.errors)[0]
13,053
#ifdef WITHOUT_FRAMEWORKS
#ifdef WITHOUT_FRAMEWORKS
13,054
#ifdef WITHOUT_FRAMEWORKS
#ifdef WITHOUT_FRAMEWORKS
13,055
def convert_path (pathname): """Return 'pathname' as a name that will work on the native filesystem, i.e. split it on '/' and put it back together again using the current directory separator. Needed because filenames in the setup script are always supplied in Unix style, and have to be converted to the local conventio...
def convert_path (pathname): """Return 'pathname' as a name that will work on the native filesystem, i.e. split it on '/' and put it back together again using the current directory separator. Needed because filenames in the setup script are always supplied in Unix style, and have to be converted to the local conventio...
13,056
def after(self, ms, func=None, *args): """Call function once after given time.
def after(self, ms, func=None, *args): """Call function once after given time.
13,057
def callit(func=func, args=args, self=self, tmp=tmp): try: func(*args) finally: try: self.deletecommand(tmp[0]) except TclError: pass
def callit(func=func, args=args, self=self, tmp=tmp): try: func(*args) finally: try: self.deletecommand(name) except TclError: pass
13,058
def callit(func=func, args=args, self=self, tmp=tmp): try: func(*args) finally: try: self.deletecommand(tmp[0]) except TclError: pass
def callit(func=func, args=args, self=self, tmp=tmp): try: func(*args) finally: try: self.deletecommand(tmp[0]) except TclError: pass
13,059
def setup(self): self.connection = self.request self.rfile = self.connection.makefile('rb', 0) self.wfile = self.connection.makefile('wb', 0)
def setup(self): self.connection = self.request self.rfile = self.connection.makefile('rb', 0) self.wfile = self.connection.makefile('wb', 0)
13,060
def %s(self, *args): return apply(getattr(self.mod, self.name).%s, args)
def %s(self, *args): return apply(getattr(self.mod, self.name).%s, args)
13,061
def __init__(self, mod, name): self.mod = mod self.name = name
def __init__(self, mod, name): self.mod = mod self.name = name
13,062
def __init__(self, *args):
def __init__(self, *args):
13,063
def set_rexec(self, rexec):
def set_rexec(self, rexec):
13,064
def is_builtin(self, name):
def is_builtin(self, name):
13,065
def init_builtin(self, name):
def init_builtin(self, name):
13,066
def load_dynamic(self, name, filename, file):
def load_dynamic(self, name, filename, file):
13,067
def add_module(self, name):
def add_module(self, name):
13,068
def modules_dict(self):
def modules_dict(self):
13,069
def default_path(self):
def default_path(self):
13,070
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
13,071
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
13,072
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
13,073
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
13,074
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
def reload(self, module, path=None): if path is None and hasattr(module, '__filename__'): head, tail = os.path.split(module.__filename__) path = [os.path.join(head, '')] return ihooks.ModuleImporter.reload(self, module, path)
13,075
def __init__(self, hooks = None, verbose = 0):
def __init__(self, hooks = None, verbose = 0):
13,076
def set_trusted_path(self):
def set_trusted_path(self):
13,077
def load_dynamic(self, name, filename, file):
def load_dynamic(self, name, filename, file):
13,078
def make_initial_modules(self):
def make_initial_modules(self):
13,079
def is_builtin(self, mname):
def is_builtin(self, mname):
13,080
def make_builtin(self):
def make_builtin(self):
13,081
def make_main(self):
def make_main(self):
13,082
def make_osname(self):
def make_osname(self):
13,083
def make_sys(self):
def make_sys(self):
13,084
def copy_except(self, src, exceptions):
def copy_except(self, src, exceptions):
13,085
def copy_only(self, src, names):
def copy_only(self, src, names):
13,086
def copy_none(self, src):
def copy_none(self, src):
13,087
def add_module(self, mname):
def add_module(self, mname):
13,088
def r_exec(self, code):
def r_exec(self, code):
13,089
def r_eval(self, code):
def r_eval(self, code):
13,090
def r_execfile(self, file):
def r_execfile(self, file):
13,091
def r_import(self, mname, globals={}, locals={}, fromlist=[]):
def r_import(self, mname, globals={}, locals={}, fromlist=[]):
13,092
def make_delegate_files(self): s = self.modules['sys']
def make_delegate_files(self): s = self.modules['sys']
13,093
def set_files(self):
def set_files(self):
13,094
def set_files(self):
def set_files(self):
13,095
def reset_files(self):
def reset_files(self):
13,096
def reset_files(self):
def reset_files(self):
13,097
def restore_files(self):
def restore_files(self):
13,098
def s_apply(self, func, args=(), kw=None):
def s_apply(self, func, args=(), kw=None):
13,099