bcurtiss@bcurtiss-laptop:~$ ipython
Python 2.7.12 (default, Oct 8 2019, 14:14:10)
Type "copyright", "credits" or "license" for more information.
IPython 2.4.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.
AttributeError: 'module' object has no attribute 'O_PATH'
In [2]: exit
bcurtiss@bcurtiss-laptop:~$ ipython3
Python 3.5.2 (default, Oct 8 2019, 13:06:37)
Type "copyright", "credits" or "license" for more information.
IPython 2.4.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.
In [1]: import apport_python_hook; apport_python_hook.apport_excepthook(Exception, Exception(), None)
Exception
Here's a reproduction of the error:
bcurtiss@ bcurtiss- laptop: ~$ ipython
Python 2.7.12 (default, Oct 8 2019, 14:14:10)
Type "copyright", "credits" or "license" for more information.
IPython 2.4.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.
In [1]: import apport_python_hook; apport_ python_ hook.apport_ excepthook( Exception, Exception(), None) ------- ------- ------- ------- ------- ------- ------- ------- ------- ----- input-1- e8f288b62cb1> in <module>() python_ hook.apport_ excepthook( Exception, Exception(), None)
Exception
-------
AttributeError Traceback (most recent call last)
<ipython-
----> 1 import apport_python_hook; apport_
/usr/lib/ python2. 7/dist- packages/ apport_ python_ hook.pyc in apport_ excepthook( exc_type, exc_obj, exc_tb) print_exception (exc_type, exc_obj, exc_tb, file=tb_file) getvalue( ).strip( ) proc_info( extraenv= ['PYTHONPATH' , 'PYTHONHOME'])
107 traceback.
108 pr['Traceback'] = tb_file.
--> 109 pr.add_
110 pr.add_user_info()
111 # override the ExecutablePath with the script that was actually running
/usr/lib/ python2. 7/dist- packages/ apport/ report. pyc in add_proc_info(self, pid, proc_pid_fd, extraenv)
517 self.pid = int(pid)
518 pid = str(pid)
--> 519 proc_pid_fd = os.open('/proc/%s' % pid, os.O_RDONLY | os.O_PATH | os.O_DIRECTORY)
520
521 try:
AttributeError: 'module' object has no attribute 'O_PATH'
In [2]: exit bcurtiss- laptop: ~$ ipython3
bcurtiss@
Python 3.5.2 (default, Oct 8 2019, 13:06:37)
Type "copyright", "credits" or "license" for more information.
IPython 2.4.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.
In [1]: import apport_python_hook; apport_ python_ hook.apport_ excepthook( Exception, Exception(), None)
Exception
In [2]: exit bcurtiss- laptop: ~$
bcurtiss@