osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

socket: Did I find a bug?


This is on a debian 9 box python 2.7.13

My interpretation is that a timeout exception is thrown and that the
args attribute of such an exception is an empty tuple which then causes
an IndexError in line 482 of module /usr/lib/python2.7/socket.py. Does
that soundplausible?

Here is the traceback:

Traceback (most recent call last):
  File "/usr/local/lib/python-apps/rmtdump/pymain.py", line 101, in main
    Exit_Nr = process(sys.argv)
  File "/usr/local/lib/python-apps/rmtdump/rmtdump.py", line 249, in program
    process(path)
  File "/usr/local/lib/python-apps/rmtdump/rmtdump.py", line 184, in process
    of = rmt.open(rpj(rmt5lcl(rt), archive), "wb")
  File "/usr/local/lib/python-apps/rmtdump/ftputil.py", line 211, in open
    return ftpfile(ftp, fn, mode, True)
  File "/usr/local/lib/python-apps/rmtdump/ftputil.py", line 70, in __init__
    self.cnct =  self.ftp.transfercmd("%s %s" % (cmd, rfn))
  File "/usr/lib/python2.7/ftplib.py", line 376, in transfercmd
    return self.ntransfercmd(cmd, rest)[0]
  File "/usr/lib/python2.7/ftplib.py", line 710, in ntransfercmd
    conn, size = FTP.ntransfercmd(self, cmd, rest)
  File "/usr/lib/python2.7/ftplib.py", line 339, in ntransfercmd
    resp = self.sendcmd(cmd)
  File "/usr/lib/python2.7/ftplib.py", line 249, in sendcmd
    return self.getresp()
  File "/usr/lib/python2.7/ftplib.py", line 215, in getresp
    resp = self.getmultiline()
  File "/usr/lib/python2.7/ftplib.py", line 201, in getmultiline
    line = self.getline()
  File "/usr/lib/python2.7/ftplib.py", line 186, in getline
    line = self.file.readline(self.maxline + 1)
  File "/usr/lib/python2.7/socket.py", line 482, in readline
    if e.args[0] == EINTR:
IndexError: tuple index out of range
Locals by frame, innermost last

Frame main in /usr/local/lib/python-apps/rmtdump/pymain.py at line 119
           backtrace = <function backtrace at 0x7f8f3311a050>
                 fun = <function configbackup at 0x7f8f341facf8>
                  pn = 'rmtdump'
             process = <function program at 0x7f8f33195f50>

Frame program in /usr/local/lib/python-apps/rmtdump/rmtdump.py at line 281
             ErrInfo = IndexError('tuple index out of range',)
             aborted = True
                argv = ['/usr/local/sbin/rmtdump']
                path = '/home/antoon'

Frame process in /usr/local/lib/python-apps/rmtdump/rmtdump.py at line 208
             ErrInfo = IndexError('tuple index out of range',)
                b_rt = '/home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be'
          backupflag = 'rwx'
         backupstamp = 1520450190
          checkstamp = 1519846075
          cleanstamp = 1
                dirs = ['Archives-1.sbd', 'INBOX.sbd']
             entries = ['@TODO.msf', 'Archives-1.msf', 'Archives-1.sbd', 'Archives.msf', 'Drafts-1.msf', 'Drafts.msf', 'INBOX', ...
               entry = 'msgFilterRules.dat'
           file_info = posix.stat_result(st_mode=33188, st_ino=10365097, st_dev=2058, st_nlink=1, st_uid=1000, st_gid=1000, st_ ...
            fileinfo = posix.stat_result(st_mode=33152, st_ino=10621705, st_dev=2058, st_nlink=1, st_uid=1000, st_gid=1000, st_ ...
               files = ['Junk.msf', 'Drafts.msf', 'filterlog.html', 'Drafts-1.msf', 'Archives.msf', 'junklog.html', 'msgFilterR ...
           filestamp = 1463826952.531162
                fqpn = '/home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/msgFilterRules.dat'
              islink = <function islink at 0x7f8f356a6500>
             ismount = <function ismount at 0x7f8f356a6758>
                last = 1520450604.318512
            ls_stamp = ['+1520450190', '1519846075', '1', '0', '0']
               newfn = 'home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!2018-03-07 at 20_16_30-tbz'
                 now = 1520450549
         nr_of_tries = 0
                  of = None
               oldfn = 'home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                path = '/home/antoon'
                  rt = '/home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be'
            st_stamp = '+1520450190:1519846075:1'
               stamp = '1'
               start = 1520450604
                  tf = <tarfile.TarFile object at 0x7f8f33192650>
              timefn = '!2018-03-07 at 20_16_30-tbz'
               tryal = 0
              update = True

Frame open in /usr/local/lib/python-apps/rmtdump/ftputil.py at line 211
                  fn = 'home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                 ftp = FTPS(antoon at pardon-sleeuwaegen.be@xxxxxxxxxxxxxx)
                mode = 'wb'
                self = FTPS(antoon at pardon-sleeuwaegen.be@xxxxxxxxxxxxxx)

Frame __init__ in /usr/local/lib/python-apps/rmtdump/ftputil.py at line 70
               bound = True
                  ch = 'b'
                 cmd = 'STOR'
                  cn = FTPS(antoon at pardon-sleeuwaegen.be@xxxxxxxxxxxxxx)
               count = 1
                mode = 'wb'
                 rfn = 'home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                self = None

Frame transfercmd in /usr/lib/python2.7/ftplib.py at line 376
                 cmd = 'STOR home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                rest = None
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>

Frame ntransfercmd in /usr/lib/python2.7/ftplib.py at line 710
                 cmd = 'STOR home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                rest = None
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>

Frame ntransfercmd in /usr/lib/python2.7/ftplib.py at line 352
                 cmd = 'STOR home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                conn = <socket._socketobject object at 0x7f8f33165c20>
                host = '192.110.0.56'
                port = 62332
                rest = None
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>
                size = None

Frame sendcmd in /usr/lib/python2.7/ftplib.py at line 249
                 cmd = 'STOR home/antoon/.icedove/clam9zaw.default/ImapMail/mail.priorweb.be/!ENTRY-tbz'
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>

Frame getresp in /usr/lib/python2.7/ftplib.py at line 215
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>

Frame getmultiline in /usr/lib/python2.7/ftplib.py at line 201
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>

Frame getline in /usr/lib/python2.7/ftplib.py at line 186
                self = <ftplib.FTP_TLS instance at 0x7f8f33125560>

Frame readline in /usr/lib/python2.7/socket.py at line 482
                 buf = <cStringIO.StringO object at 0x7f8f3312ebc8>
             buf_len = 0
                   e = timeout()
                self = <socket._fileobject object at 0x7f8f33182e50>
                size = 8193