nullx002 / pychess

Automatically exported from code.google.com/p/pychess
GNU General Public License v3.0
1 stars 0 forks source link

python interpreter crash when using FICS #880

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
As with issue 878, at the time of the crash I was running with a patch to make 
glock usage in FICS callbacks more fine grained, so this might be specific to 
that patch rather than a problem with hg tip. I doubt it is specific to that 
patch though, because I've seen these types of crashes before.

Fatal Python error: Inconsistent interned string state.
Fatal Python error: Aborted

Thread 0x00007f3ba67ec700:
  File "/usr/lib64/python2.7/threading.py", line 339 in wait
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 114 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

[ previous thread repeated 40 times ... ]

Thread 0x00007f3c2affd700:
  File "/usr/lib64/python2.7/threading.py", line 339 in wait
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 114 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c2bfff700:
  File "/usr/lib64/python2.7/threading.py", line 339 in wait
  File "/usr/lib64/python2.7/Queue.py", line 168 in get
  File "/home/gatto/code/hg/pychess/lib/pychess/System/GtkWorker.py", line 30 in run
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 62 in <lambda>
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 91 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c377fe700:
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/FICSConnection.py", line 280 in keep_alive
  File "/usr/lib64/python2.7/threading.py", line 764 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c37fff700:
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/FICSConnection.py", line 280 in keep_alive
  File "/usr/lib64/python2.7/threading.py", line 764 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c449bb700:
  File "/usr/lib64/python2.7/threading.py", line 339 in wait
  File "/usr/lib64/python2.7/Queue.py", line 168 in get
  File "/home/gatto/code/hg/pychess/lib/pychess/System/GtkWorker.py", line 30 in run
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 62 in <lambda>
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 91 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c455c5700:
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/TimeSeal.py", line 162 in cook_some
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/TimeSeal.py", line 159 in readuntil
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/TimeSeal.py", line 150 in readline
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py", line 161 in _get_lines
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py", line 156 in popleft
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py", line 206 in parse
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/FICSConnection.py", line 294 in run
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 62 in <lambda>
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 91 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c466f8700:
  File "/home/gatto/code/hg/pychess/lib/pychess/System/debug.py", line 29 in thread_dumper
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 62 in <lambda>
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 91 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Current thread 0x00007f3c51644700:
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py", line 48 in handle
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py", line 222 in test_prediction
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py", line 213 in parse
  File "/home/gatto/code/hg/pychess/lib/pychess/ic/FICSConnection.py", line 294 in run
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 62 in <lambda>
  File "/home/gatto/code/hg/pychess/lib/pychess/System/ThreadPool.py", line 91 in run
  File "/usr/lib64/python2.7/threading.py", line 811 in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 784 in __bootstrap

Thread 0x00007f3c5ec74740:
  File "/home/gatto/code/hg/pychess/lib/pychess/Main.py", line 492 in run
  File "/home/gatto/code/hg/pychess/pychess", line 138 in <module>

End of log:

22:03:45 (139896825820928, 'ICLounge.__init__:48', 'glock.acquire') DEBUG: -> 
threads_enter
22:03:45 (139896825820928, 'ICLounge.__init__:48', 'glock.acquire') DEBUG: <- 
threads_enter
22:03:45 ('mgatto', 'GTS.onGameAdd') DEBUG: <FICSGame wplayer=<FICSPlayer 
name='olte', id=139896960045696, online=True, adjournment=False, status=0, 
game.gameno=51, game.rated=True, game.private=False, Blitz=1663, Standard=2032, 
Lightning=1675, Atomic=1697, Bughouse=0, Crazyhouse=1338, Losers=0, 
Suicide=1382, Wild=1640>, bplayer=<FICSPlayer name='MyDonna', 
id=139896960185600, online=True, adjournment=False, status=0, game.gameno=51, 
game.rated=True, game.private=False, Blitz=1718, Standard=2347, Lightning=2541, 
Atomic=0, Bughouse=0, Crazyhouse=0, Losers=0, Suicide=0, Wild=0>, gameno=51, 
game_type=<GameType fics_name='blitz', display_text='Blitz'>, rated=True, 
private=False>
22:03:45 (139896825820928, 'ICLounge.__init__:48', 'glock.release') DEBUG: -> 
threads_leave
22:03:45 (139896825820928, 'ICLounge.__init__:48', 'glock.release') DEBUG: <- 
threads_leave
22:03:45 (139896825820928, 'ICLounge.__init__:48', 'glock.release') DEBUG: -> 
_rlock.release
22:03:45 (139896825820928, 'ICLounge.__init__:48', 'glock.release') DEBUG: <- 
_rlock.release
22:03:45 ('GuestQCHS', 'on_player_unavailable') DEBUG: nlte is no longer 
available for matches.
22:03:45 ('GuestQCHS', 'lines') DEBUG: 
22:03:45 ('GuestQCHS', 'lines') DEBUG: MyDonna is no longer available for 
matches.

Original issue reported on code.google.com by mattgatto on 1 Jun 2014 at 5:46

GoogleCodeExporter commented 8 years ago
I loaded the coredump into gdb and got this:

(gdb) bt
#0  0x000000308e40ee6b in raise (sig=6)
    at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:37
#1  <signal handler called>
#2  0x000000308e0359e9 in __GI_raise (sig=sig@entry=6)
    at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
#3  0x000000308e0370f8 in __GI_abort () at abort.c:90
#4  0x00000030a92f8b5e in Py_FatalError (
    msg=msg@entry=0x30a9329d50 "Inconsistent interned string state.")
    at /usr/src/debug/Python-2.7.5/Python/pythonrun.c:1697
#5  0x00000030a928d2c1 in string_dealloc (
    op='nlte is no longer available for matches.')
    at /usr/src/debug/Python-2.7.5/Objects/stringobject.c:595
#6  0x00000030a9297c13 in tupledealloc (op=0x7f3c4c05ccd0)
    at /usr/src/debug/Python-2.7.5/Objects/tupleobject.c:238
#7  0x00000030a927cf6f in insertdict_by_entry (mp=0x7f3c4c02c6e0, 
    key='matches', hash=<optimized out>, ep=<optimized out>, 
    value=<optimized out>)
    at /usr/src/debug/Python-2.7.5/Objects/dictobject.c:528
#8  0x00000030a927e8c0 in dict_set_item_by_hash_or_entry (
    op=op@entry={'matches': ('MyDonna is no longer available for matches.',), 'callback': <instancemethod at remote 0x7f3c3c077e60>, 'hash': 8269518719085339141, 'name': 'on_player_unavailable', 'regexps': [<_sre.SRE_Pattern at remote 0x7f3c4c0315b0>]}, key=<optimized out>, hash=<optimized out>, ep=ep@entry=0x0, 
    value=value@entry=('MyDonna is no longer available for matches.',))
    at /usr/src/debug/Python-2.7.5/Objects/dictobject.c:774
#9  0x00000030a927f804 in PyDict_SetItem (
    op=op@entry={'matches': ('MyDonna is no longer available for matches.',), 'callback': <instancemethod at remote 0x7f3c3c077e60>, 'hash': 8269518719085339141, 'name': 'on_player_unavailable', 'regexps': [<_sre.SRE_Pattern at remote 0x7f3c4c0315b0>]}, key=key@entry='matches', 
    value=value@entry=('MyDonna is no longer available for matches.',))
    at /usr/src/debug/Python-2.7.5/Objects/dictobject.c:827
#10 0x00000030a9284a88 in _PyObject_GenericSetAttrWithDict (
    obj=<optimized out>, name='matches', 
    value=('MyDonna is no longer available for matches.',), 
---Type <return> to continue, or q <return> to quit---
    dict={'matches': ('MyDonna is no longer available for matches.',), 'callback': <instancemethod at remote 0x7f3c3c077e60>, 'hash': 8269518719085339141, 'name': 'on_player_unavailable', 'regexps': [<_sre.SRE_Pattern at remote 0x7f3c4c0315b0>]}) at /usr/src/debug/Python-2.7.5/Objects/object.c:1529
#11 0x00000030a92844ff in PyObject_SetAttr (
    v=v@entry=<LinePrediction(matches=('MyDonna is no longer available for matches.',), callback=<instancemethod at remote 0x7f3c3c077e60>, hash=8269518719085339141, name='on_player_unavailable', regexps=[<_sre.SRE_Pattern at remote 0x7f3c4c0315b0>]) at remote 0x7f3c3c075c50>, name=<optimized out>, 
    value=value@entry=('MyDonna is no longer available for matches.',))
    at /usr/src/debug/Python-2.7.5/Objects/object.c:1252
#12 0x00000030a92dae88 in PyEval_EvalFrameEx (
    f=f@entry=Frame 0x7f3c1804ec20, for file /home/gatto/code/hg/pychess/lib/pychess/ic/VerboseTelnet.py, line 48, in handle (self=<LinePrediction(matches=('MyDonna is no longer available for matches.',), callback=<instancemethod at remote 0x7f3c3c077e60>, hash=8269518719085339141, name='on_player_unavailable', regexps=[<_sre.SRE_Pattern at remote 0x7f3c4c0315b0>]) at remote 0x7f3c3c075c50>, line='MyDonna is no longer available for matches.', match=<_sre.SRE_Match at remote 0x7f3c0036a828>), throwflag=throwflag@entry=0)
    at /usr/src/debug/Python-2.7.5/Python/ceval.c:2078
#13 0x00000030a92dd80c in fast_function (nk=<optimized out>, na=2, n=2, 
    pp_stack=0x7f3c51643030, func=<function at remote 0x1b000c8>)
    at /usr/src/debug/Python-2.7.5/Python/ceval.c:4184

Original comment by mattgatto on 1 Jun 2014 at 7:52

GoogleCodeExporter commented 8 years ago

Original comment by mattgatto on 1 Jun 2014 at 11:56

Attachments:

GoogleCodeExporter commented 8 years ago

Original comment by mattgatto on 26 Jun 2014 at 11:30