Re: terminate called after throwing an instance of 'CABRTException'

Discussion in 'Python' started by Daniel Fetchinson, Oct 2, 2012.

  1. >> I've noticed a strange thing with python lately:
    >>
    >>
    >>
    >> Python 2.6.2 (r262:71600, Aug 21 2009, 12:23:57)
    >> [GCC 4.4.1 20090818 (Red Hat 4.4.1-6)] on linux2
    >> Type "help", "copyright", "credits" or "license" for more information.
    >>>>> def f(): print x

    >> ...
    >>>>> f()

    >> terminate called after throwing an instance of 'CABRTException'
    >> Traceback (most recent call last):
    >> File "<stdin>", line 1, in <module>
    >> File "<stdin>", line 1, in f
    >> NameError: global name 'x' is not defined
    >>>>>

    >>
    >>
    >>
    >> Clearly there is a NameError because x is not defined, but what the
    >> hell is the "terminate ..... 'CABRTException'" business?
    >>
    >> I guess it has to do with abrt but abrt is not running on my system at
    >> all. Also, if I run python2.7 with the above code I don't get the
    >> CABRTException stuff. What is really strange is that I have all sorts
    >> of recent files in /var/cache/abrt/pyhook-* indicating that somehow
    >> abrt is doing things even though it is not running, for instance
    >> chkconfig --list | grep abrt shows it off in all run levels.
    >>
    >> What's going on?

    >
    > No idea, but I'd have a look at sys.modules, and if
    >
    >>>> import sys
    >>>> [name for name in sys.modules if "abrt" in name.lower()]

    > []
    >
    > gives a non-empty result I'd investigate where the culprit is imported --
    > /usr/lib/python2.6/sitecustomize.py would be the obvious candidate.


    Indeed! Thanks a lot,
    /usr/lib/python2.6/site-packages/sitecustomize.py was created by the
    package abrt-addon-python (at least this is the fedora name) and so it
    was activated by python itself completely independently from abrt
    (which was not running).

    Now I removed all packages called abrt-* and the problem is gone.

    Cheers,
    Daniel


    --
    Psss, psss, put it down! - http://www.cafepress.com/putitdown
    Daniel Fetchinson, Oct 2, 2012
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mohsen
    Replies:
    14
    Views:
    13,961
    Nate Barney
    Nov 8, 2006
  2. Philipp Kraus
    Replies:
    7
    Views:
    910
    Philipp Kraus
    Jul 17, 2011
  3. peter koch
    Replies:
    1
    Views:
    329
    Ian Collins
    Jul 14, 2011
  4. Daniel Fetchinson
    Replies:
    0
    Views:
    183
    Daniel Fetchinson
    Oct 2, 2012
  5. Peter Otten
    Replies:
    0
    Views:
    186
    Peter Otten
    Oct 2, 2012
Loading...

Share This Page