MCPcopy Create free account
hub / github.com/ipython/ipython / ofind

Method ofind

IPython/core/splitinput.py:121–134  ·  view source on GitHub ↗

Do a full, attribute-walking lookup of the ifun in the various namespaces for the given IPython InteractiveShell instance. Return a dict with keys: {found, obj, ospace, ismagic} Note: can cause state changes because of calling getattr, but should only be run if auto

(self, ip)

Source from the content-addressed store, hash-verified

119 self.pre_whitespace = self.pre
120
121 def ofind(self, ip):
122 """Do a full, attribute-walking lookup of the ifun in the various
123 namespaces for the given IPython InteractiveShell instance.
124
125 Return a dict with keys: {found, obj, ospace, ismagic}
126
127 Note: can cause state changes because of calling getattr, but should
128 only be run if autocall is on and if the line hasn't matched any
129 other, less dangerous handlers.
130
131 Does cache the results of the call, so can be called multiple times
132 without worrying about *further* damaging state.
133 """
134 return ip._ofind(self.ifun)
135
136 def __str__(self):
137 return "LineInfo [%s|%s|%s|%s]" %(self.pre, self.esc, self.ifun, self.the_rest)

Callers 2

checkMethod · 0.80
handleMethod · 0.80

Calls 1

_ofindMethod · 0.80

Tested by

no test coverage detected