You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On first hit of the breaskpoint if I continue and on the second hit of the op(i) throws exception.
The traceback:
Traceback (most recent call last):
File "/Users/-----------/test.py", line 10, in <module>
op(i)
File "/opt/homebrew/lib/python3.11/site-packages/objprint/objprint.py", line 95, in __call__
args = self.frame_analyzer.get_args(call_frame)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/objprint/frame_analyzer.py", line 20, in get_args
func_call_str = self.get_executing_function_call_str(frame)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/objprint/frame_analyzer.py", line 58, in get_executing_function_call_str
source = inspect.getsource(module)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/[email protected]/3.11.9_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/inspect.py", line 1258, in getsource
lines, lnum = getsourcelines(object)
^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/[email protected]/3.11.9_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/inspect.py", line 1240, in getsourcelines
lines, lnum = findsource(object)
^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/[email protected]/3.11.9_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/inspect.py", line 1059, in findsource
file = getsourcefile(object)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/[email protected]/3.11.9_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/inspect.py", line 936, in getsourcefile
filename = getfile(object)
^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/[email protected]/3.11.9_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/inspect.py", line 897, in getfile
raise TypeError('{!r} is a built-in module'.format(object))
TypeError: <module '__main__'> is a built-in module
If you suspect this is an IPython 8.12.0 bug, please report it at:
https://github.com/ipython/ipython/issues
or send an email to the mailing list at [email protected]
You can print a more detailed traceback right now with "%tb", or use "%debug"
to interactively debug it.
Extra-detailed tracebacks for bug-reporting purposes can be enabled via:
%config Application.verbose_crash=True
The text was updated successfully, but these errors were encountered:
arg_name=True requires the source code access but ipython definitely does something weird when it enters the debugger. If you throw out arg_name=True this should work fine.
Thank you for the workaround. That being said I do think an exception shouldn't be thrown since this is primarily a debugging tool. Is it possible to just catch the exception and leave the source line empty?
On first hit of the breaskpoint if I continue and on the second hit of the
op(i)
throws exception.The traceback:
The text was updated successfully, but these errors were encountered: