Extension module mystery
Fredrik Lundh
fredrik at pythonware.com
Mon Jul 26 15:09:21 EDT 1999
More information about the Python-list mailing list
Mon Jul 26 15:09:21 EDT 1999
- Previous message (by thread): createfilehandler, how to use it with Tk?
- Next message (by thread): Extension module mystery
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Markus Demleitner <msdemlei at tucana.harvard.edu> wrote: > Now, when I try the following: > lis = ldw.ldw("Hol",["Kohl","Pfohl"]) > a = max(lis) > (ldw.ldw being the glue function), I get > Traceback (innermost last): > File "zw.py", line 3, in ? > a = max(lis) > TypeError: argument 2: expected string, list found > (that's python 1.5.2, FWIW). Odd, isn't it? Why > should max insist on a string? maybe it isn't max that generates that error; instead, it looks like you've missed to test for a Python exception somewhere (if you ignore errors, and don't call PyErr_Clear() to clean up, Python may raise them later...) could it be that you forgot to change the glue function to look for an object rather than a string? </F>
- Previous message (by thread): createfilehandler, how to use it with Tk?
- Next message (by thread): Extension module mystery
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list