Menu

error on new pydb install

Help
2008-01-16
2012-12-10
  • Tennis Smith

    Tennis Smith - 2008-01-16

    Hi,

    I just installed pydb and it appeared to be ok.  But, when I try to start the debugger, I get:
    Debugger exited abnormally with code 1
    Current directory is /home/tennis/
    Traceback (most recent call last):
      File "/usr/local/bin/pydb", line 724, in <module>
        main()
      File "/usr/local/bin/pydb", line 605, in main
        p = Pdb()
      File "/usr/local/bin/pydb", line 213, in __init__
        Gdb.__init__(self, completekey, stdin, stdout, siglist)
      File "/opt/ActivePython-2.5/lib/python2.5/site-packages/pydb/gdb.py", line 78, in __init__
        ignore_list=siglist)
      File "/opt/ActivePython-2.5/lib/python2.5/site-packages/pydb/sighandler.py", line 143, in __init__
        pass_along=False)
      File "/opt/ActivePython-2.5/lib/python2.5/site-packages/pydb/sighandler.py", line 343, in __init__
        if signame in self.sigs:
    AttributeError: SigHandler instance has no attribute 'sigs'

    Debugger exited abnormally with code 1

    I am using fedora 7 with emacs 23.0.0.1

     
    • Rocky Bernstein

      Rocky Bernstein - 2008-01-16

      Looks like a bug to me.

      Try this patch. If it works let me know and I'll put it on CVS.

      Index: pydb/sighandler.py

      RCS file: /cvsroot/bashdb/pydb/pydb/sighandler.py,v
      retrieving revision 1.30
      diff -u -r1.30 sighandler.py
      --- pydb/sighandler.py    14 Jan 2007 07:38:31 -0000    1.30
      +++ pydb/sighandler.py    16 Jan 2008 01:53:40 -0000
      @@ -144,7 +144,7 @@
               self.action('SIGINT stop print nostack nopass')
               return

      -    def check_and_adjust_sighandler(self, signame):
      +    def check_and_adjust_sighandler(self, signame, sigs):
               """Check to see if a single signal handler that we are interested in
               has changed or has not been set initially. On return signame
               should have our signal handler."""
      @@ -155,12 +155,12 @@
                   # On some OS's (Redhat 8), SIGNUM's are listed (like
                   # SIGRTMAX) that getsignal can't handle.
                   if signame in self.sigs:
      -                self.sigs.pop(signame)
      +                sigs.pop(signame)
                   return True
               if old_handler != self.sigs[signame].handle:
                   if old_handler not in [signal.SIG_IGN, signal.SIG_DFL]:
                       # save the program's signal handler
      -                self.sigs[signame].old_handler = old_handler
      +                sigs[signame].old_handler = old_handler

                   # set/restore _our_ signal handler
                   try:
      @@ -174,7 +174,7 @@
               """Check to see if any of the signal handlers we are interested in have
               changed or is not initially set. Change any that are not right. """
               for signame in self.sigs.keys():
      -            if not self.check_and_adjust_sighandler(signame):
      +            if not self.check_and_adjust_sighandler(signame, self.sigs):
                       break

           def print_info_signal_entry(self, signame):
      @@ -265,7 +265,7 @@
                       self.handle_print_stack(signame, on)
                   else:
                       self.pydb.errmsg('Invalid arguments')
      -        self.check_and_adjust_sighandler(signame)
      +        self.check_and_adjust_sighandler(signame, self.sigs)
               return

           def handle_print_stack(self, signame, print_stack):

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.