fails to call python from jython for types, functools, csv modules

Joax Spec joax.spec at gmail.com
Wed May 12 17:21:22 EDT 2010


Hello I'm very new to python/jython, and trying yo *call a program from
jython*, which works very good in python.
I got some issues which resolve as I expose here, but I think these are
unsatisfactory solutions.
If you want to reply please do it to my address.

thanks,
Jx

PD. both are great projects!!!

1. FIRST Error

Error !Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "__pyclasspath__/parserJoax.py", line 1, in <module>
  File "C:\Python26\lib\re.py", line 283, in <module>
    import copy_reg
  File "C:\Python26\lib\copy_reg.py", line 7, in <module>
    from types import ClassType as _ClassType
  File "C:\Python26\lib\types.py", line 36, in <module>
    BufferType = buffer
NameError: name 'buffer' is not defined

*Solution --> comment in types.py   #BufferType = buffer (line 37)*

2. SECOND Error

Error !Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "__pyclasspath__/parserJoax.py", line 3, in <module>
  File "C:\Python26\lib\csv.py", line 7, in <module>
    from functools import reduce
  File "C:\Python26\lib\functools.py", line 10, in <module>
    from _functools import partial, reduce
ImportError: cannot import name reduce

*Solution --> comment in functools.py   #, reduce (line 10)
Problem --> IDLE for windows doesn't work anymore, I mean I can lauch the
GUI, but I can still use python from command line*

3. THIRD Error

Error !Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "__pyclasspath__/parserJoax.py", line 3, in <module>
  File "C:\Python26\lib\csv.py", line 7, in <module>
    from functools import reduce
ImportError: cannot import name reduce

*Solution --> comment in csv.py  #@fieldnames.setter (line 96)*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20100512/67065260/attachment.html>


More information about the Python-list mailing list