Issue 8: Traceback when parsing userinfo packets
Status:  Fixed
Owner:
Closed:  Jan 2008
Reported by jadest...@gmail.com, Dec 9, 2007
 Posted by maxbritov at 2005-12-14 15:39:35

[2005-12-14 17:14:08] B: updateBuddy <OSCARUser 227018585, flags ['free',
'icq'], online for 41 minutes, idle for 10 minutes>
[2005-12-14 17:14:08] User: maxim@modum.by - JabberConnection sending presence
"maxim@modum.by""227018585@icq2.modum.by" "None"
"Idle 10 minutes" "None" "None" "True"
""
[2005-12-14 17:14:08] xmlify: class is <type 'str'>: Idle 10 minutes
[2005-12-14 17:14:09] LegacyList: updating contact 227018585
[2005-12-14 17:14:09] B: updateBuddy <OSCARUser 227018585, flags ['free',
'icq'], online for  41 minutes, idle for 0 minutes>
[2005-12-14 17:14:09] User: maxim@modum.by - JabberConnection sending presence
"maxim@modum.by""227018585@icq2.modum.by" "None"
"" "None" "None" "True" ""
[2005-12-14 17:14:09] LegacyList: updating contact 227018585
[2005-12-14 17:14:17] ServerDiscovery: Iq received
"maxim@modum.by/modum.by" "3674". Looking for handler
[2005-12-14 17:14:17] ServerDiscovery: Handler found "vcard-temp"
"<bound method VCardFactory.incomingIq of <misciq.VCardFactory
instance at 0xb7915fec>>"
[2005-12-14 17:14:17] VCardFactory: Retrieving vCard for user
227018585@icq2.modum.by 3674
[2005-12-14 17:14:17] AvatarCache: Getting avatar
"e94db0da7a929a821529d9486d54ea3269ec429f"
[2005-12-14 17:14:17] LegacyConnection: jabberVCardRequest 227018585
[2005-12-14 17:14:17] ICQConnection: getvCard 227018585
[2005-12-14 17:14:17] ServerDiscovery: Iq received
"maxim@modum.by/modum.by" "3675". Looking for handler
[2005-12-14 17:14:17] ServerDiscovery: Handler found "vcard-temp"
"<bound method VCardFactory.incomingIq of <misciq.VCardFactory
instance at 0xb7915fec>>"
[2005-12-14 17:14:17] VCardFactory: Retrieving vCard for user
227018585@icq2.modum.by 3675
[2005-12-14 17:14:17] AvatarCache: Getting avatar
"e94db0da7a929a821529d9486d54ea3269ec429f"
[2005-12-14 17:14:18] LegacyConnection: jabberVCardRequest 227018585
[2005-12-14 17:14:18] ICQConnection: getvCard 227018585
[2005-12-14 17:14:18] ICQConnection: gotvCard
[2005-12-14 17:14:18] VCardFactory: Sending vCard
[2005-12-14 17:14:20] Traceback (most recent call last):
[2005-12-14 17:14:20]   File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
526, in doSelect
[2005-12-14 17:14:20]     _logrun(selectable, _drdw, selectable, method, dict)
[2005-12-14 17:14:20]   File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 65, in
callWithLogger
[2005-12-14 17:14:20]     callWithContext({"system": lp}, func, *args,
**kw)
[2005-12-14 17:14:20]   File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 52, in
callWithContext
[2005-12-14 17:14:20]     return context.call({ILogContext: newCtx}, func,
*args, **kw)
[2005-12-14 17:14:20]   File
"/usr/lib/python2.3/site-packages/twisted/python/context.py", line 43,
in callWithContext
[2005-12-14 17:14:20]     return func(*args,**kw)
[2005-12-14 17:14:20] --- <exception caught here> ---
[2005-12-14 17:14:20]   File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
535, in _doReadOrWrite
[2005-12-14 17:14:20]     why = getattr(selectable, method)()
[2005-12-14 17:14:20]   File
"/usr/lib/python2.3/site-packages/twisted/internet/tcp.py", line 255,
in doRead
[2005-12-14 17:14:20]     return self.protocol.dataReceived(data)
[2005-12-14 17:14:20]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 448, in dataReceived
[2005-12-14 17:14:20]     state=func(flap)
[2005-12-14 17:14:20]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 546, in oscar_Data
[2005-12-14 17:14:20]     func(snac[2:])
[2005-12-14 17:14:20]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 1327, in oscar_15_03
[2005-12-14 17:14:20]    
city,state,phone,fax,address,zip,country,company,department,position =
self.parseWorkInfo(v[13:])
[2005-12-14 17:14:20]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 739, in parseWorkInfo
[2005-12-14 17:14:20]     departmentlen =
struct.unpack("<H",data[pos:pos+2])[0]
[2005-12-14 17:14:20] struct.error: unpack str size does not match format
2005/12/14 17:14 EET [B,client] Traceback (most recent call last):
          File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
526, in doSelect
            _logrun(selectable, _drdw, selectable, method, dict)
          File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 65, in
callWithLogger
            callWithContext({"system": lp}, func, *args, **kw)
          File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 52, in
callWithContext
            return context.call({ILogContext: newCtx}, func, *args, **kw)
          File
"/usr/lib/python2.3/site-packages/twisted/python/context.py", line 43,
in callWithContext
            return func(*args,**kw)
        --- <exception caught here> ---
          File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
535, in _doReadOrWrite
            why = getattr(selectable, method)()
          File
"/usr/lib/python2.3/site-packages/twisted/internet/tcp.py", line 255,
in doRead
           return self.protocol.dataReceived(data)
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 448, in
dataReceived
            state=func(flap)
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 546, in
oscar_Data
            func(snac[2:])
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 1327, in
oscar_15_03
           
city,state,phone,fax,address,zip,country,company,department,position
= self.parseWorkInfo(v[13:])
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 739, in
parseWorkInfo
            departmentlen = struct.unpack("<H",data[pos:pos+2])[0]
        struct.error: unpack str size does not match format

[2005-12-14 17:14:20] B: connectionLost: ICQ connection lost! Reason: [Failure
instance: Traceback: struct.error, unpack str size does not match format
]
[2005-12-14 17:14:20] User: maxim@modum.by - JabberConnection sending message
"maxim@modum.by" "icq2.modum.by" "ICQ connection lost!
Reason: [Failure instance: Traceback: struct.error, unpack str size does not
match format
]" "error"
[2005-12-14 17:14:20] jabw: Sending a Jabber message "maxim@modum.by"
"icq2.modum.by" "ICQ connection lost! Reason: [Failure instance:
Traceback: struct.error, unpack str size does not match format
]" "error"
[2005-12-14 17:14:20] xmlify: class is <type 'str'>: ICQ connection lost!
Reason: [Failure instance: Traceback: struct.error, unpack str size does not
match
format
]
2005/12/14 17:14 EET [B,client] Connection Lost! <legacy.icqt.B instance at
0xb78b314c>
[2005-12-14 17:14:20] Session: Removing "maxim@modum.by"
[2005-12-14 17:14:20] User: maxim@modum.by - JabberConnection sending presence
"maxim@modum.by""icq2.modum.by" "None"
"None" "None" "unavailable" "False"
"None"
[2005-12-14 17:14:20] LegacyConnection: removeMe
[2005-12-14 17:14:20] ICQConnection: removeMe
[2005-12-14 17:14:20] ContactList: "maxim@modum.by" removed

Posted by maxbritov at 2005-12-14 15:40:46

to Jadestorm: summary window have too small width in my browser (FF1.5) :(

Posted by jadestorm at 2005-12-14 15:45:47

summary window?

Posted by maxbritov at 2005-12-15 09:58:37

"Description:" on "Submit New". Screenshot (130k)

Posted by jadestorm at 2005-12-15 13:12:55

I don't see what you are talking about.  The image seems cut off.  I can't even
see the Description field.  The summary window has a width of 80 characters,
which is what i want it to be at.  I'd much rather the lines wrap than be 10
times wider than my browser can even display.  I can read your traceback just
fine. ;)  (if you really care about having it with absolute formatting intact,
don't paste it into the description field, put it in a text field and 'attach'
it.)  But note that I don't care about the width, it's not affecting my ability
to read and make use of your traceback for fixing pyicq.  =)

As for this actual issue, it almost seems like you are getting a partial packet
back or something.  =(  Do you happen to know if this only affects this one
UIN,
or does it affect lots of different UINs?

Posted by maxbritov at 2005-12-16 10:19:01

[2005-12-16 00:21:12] User: maxim@modum.by - JabberConnection sending presence
"maxim@modum.by""122503410@icq2.modum.by" "away"
"Idle 15 minutes - User is currently away
You can leave him/her a message" "None" "None"
"True" ""
[2005-12-16 00:21:12] xmlify: class is <type 'str'>: away
[2005-12-16 00:21:12] xmlify: class is <type 'unicode'>: Idle 15 minutes -
User is currently away You can leave him/her a message
[2005-12-16 00:21:12] LegacyList: updating contact 122503410
[2005-12-16 00:21:12] ICQConnection: gotvCard
[2005-12-16 00:21:12] VCardFactory: Sending vCard
[2005-12-16 00:21:12] ServerDiscovery: Iq received
"maxim@modum.by/modum.by" "6200". Looking for handler
[2005-12-16 00:21:12] ServerDiscovery: Handler found "vcard-temp"
"<bound method VCardFactory.incomingIq of <misciq.VCardFactory
instance at 0xb799ffec>>"
[2005-12-16 00:21:12] VCardFactory: Retrieving vCard for user
147022497@icq2.modum.by 6200
[2005-12-16 00:21:12] AvatarCache: Getting avatar
"e94db0da7a929a821529d9486d54ea3269ec429f"
[2005-12-16 00:21:12] LegacyConnection: jabberVCardRequest 147022497
[2005-12-16 00:21:12] ICQConnection: getvCard 147022497
[2005-12-16 00:21:12] ServerDiscovery: Iq received
"maxim@modum.by/modum.by" "6201". Looking for handler
[2005-12-16 00:21:12] ServerDiscovery: Handler found "vcard-temp"
"<bound method VCardFactory.incomingIq of <misciq.VCardFactory
instance at 0xb799ffec>>"
[2005-12-16 00:21:12] VCardFactory: Retrieving vCard for user
122503410@icq2.modum.by 6201
[2005-12-16 00:21:12] AvatarCache: Getting avatar
"e94db0da7a929a821529d9486d54ea3269ec429f"
[2005-12-16 00:21:12] LegacyConnection: jabberVCardRequest 122503410
[2005-12-16 00:21:12] ICQConnection: getvCard 122503410
[2005-12-16 00:21:12] ICQConnection: gotvCard
[2005-12-16 00:21:12] VCardFactory: Sending vCard
[2005-12-16 00:21:12] Traceback (most recent call last):
[2005-12-16 00:21:12]   File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
526, in doSelect
[2005-12-16 00:21:12]     _logrun(selectable, _drdw, selectable, method, dict)
[2005-12-16 00:21:12]   File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 65, in
callWithLogger
[2005-12-16 00:21:12]     callWithContext({"system": lp}, func, *args,
**kw)
[2005-12-16 00:21:12]   File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 52, in
callWithContext
[2005-12-16 00:21:12]     return context.call({ILogContext: newCtx}, func,
*args, **kw)
[2005-12-16 00:21:12]   File
"/usr/lib/python2.3/site-packages/twisted/python/context.py", line 43,
in callWithContext
[2005-12-16 00:21:12]     return func(*args,**kw)
[2005-12-16 00:21:12] --- <exception caught here> ---
[2005-12-16 00:21:12]   File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
535, in _doReadOrWrite
[2005-12-16 00:21:12]     why = getattr(selectable, method)()
[2005-12-16 00:21:12]   File
"/usr/lib/python2.3/site-packages/twisted/internet/tcp.py", line 255,
in doRead
[2005-12-16 00:21:12]     return self.protocol.dataReceived(data)
[2005-12-16 00:21:12]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 448, in dataReceived
[2005-12-16 00:21:12]     state=func(flap)
[2005-12-16 00:21:12]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 546, in oscar_Data
[2005-12-16 00:21:12]     func(snac[2:])
[2005-12-16 00:21:12]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 1327, in oscar_15_03
[2005-12-16 00:21:12]    
city,state,phone,fax,address,zip,country,company,department,position =
self.parseWorkInfo(v[13:])
[2005-12-16 00:21:12]   File "/usr/local/pyicq2/src/tlib/oscar.py",
line 739, in parseWorkInfo
[2005-12-16 00:21:12]     departmentlen =
struct.unpack("<H",data[pos:pos+2])[0]
[2005-12-16 00:21:12] struct.error: unpack str size does not match format
2005/12/16 00:21 EET [B,client] Traceback (most recent call last):
          File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
526, in doSelect
            _logrun(selectable, _drdw, selectable, method, dict)
          File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 65, in
callWithLogger
            callWithContext({"system": lp}, func, *args, **kw)
          File
"/usr/lib/python2.3/site-packages/twisted/python/log.py", line 52, in
callWithContext
            return context.call({ILogContext: newCtx}, func, *args, **kw)
          File
"/usr/lib/python2.3/site-packages/twisted/python/context.py", line 43,
in callWithContext
            return func(*args,**kw)
        --- <exception caught here> ---
          File
"/usr/lib/python2.3/site-packages/twisted/internet/default.py", line
535, in _doReadOrWrite
            why = getattr(selectable, method)()
          File
"/usr/lib/python2.3/site-packages/twisted/internet/tcp.py", line 255,
in doRead
            return self.protocol.dataReceived(data)
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 448, in
dataReceived
            state=func(flap)
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 546, in
oscar_Data
            func(snac[2:])
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 1327, in
oscar_15_03
           
city,state,phone,fax,address,zip,country,company,department,position
= self.parseWorkInfo(v[13:])
          File "/usr/local/pyicq2/src/tlib/oscar.py", line 739, in
parseWorkInfo
            departmentlen = struct.unpack("<H",data[pos:pos+2])[0]
        struct.error: unpack str size does not match format

[2005-12-16 00:21:12] B: connectionLost: ICQ connection lost! Reason: [Failure
instance: Traceback: struct.error, unpack str size does not match format]
[2005-12-16 00:21:12] User: maxim@modum.by - JabberConnection sending message
"maxim@modum.by" "icq2.modum.by" "ICQ connection lost!
Reason: [Failure instance: Traceback: struct.error, unpack str size does not
match format]" "error"
[2005-12-16 00:21:12] jabw: Sending a Jabber message "maxim@modum.by"
"icq2.modum.by" "ICQ connection lost! Reason: [Failure instance:
Traceback: struct.error, unpack str size does not match format]"
"error"
[2005-12-16 00:21:12] xmlify: class is <type 'str'>: ICQ connection lost!
Reason: [Failure instance: Traceback: struct.error, unpack str size does not
match format]
2005/12/16 00:21 EET [B,client] Connection Lost! <legacy.icqt.B instance at
0xb38badec>
[2005-12-16 00:21:12] Session: Removing "maxim@modum.by"


Jan 12, 2008
Project Member #1 volk...@gmail.com
This may be fixed by the latest "don't crash on weird encoding" patches.
Status: Fixed