Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

Installing drPythonon RHEL 5.5 x64

Help
Antares
2010-09-08
2013-04-26
  • Antares
    Antares
    2010-09-08

    Hi,
    I tried to install the newest version of drPython on my Redhat Enterprise Linux 5.5 (Tikanga) box.

    $ uname -a
    Linux myhost 2.6.18-194.11.3.el5 #1 SMP Mon Aug 23 15:51:38 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux
    $ python -V
    Python 2.4.3
    

    Note: Updating to a newer Python is not an option.

    In order to meet the prereqs, I downloaded several rpm and -test ed them. These were found to be the newest available for Python 2.4 that would install with no errors.
    SDL-1.2.11-1.fc6.i386.rpm
    wxPython-common-gtk2-unicode-2.8.9.1-fc6_py2.4.i386.rpm
    wxPython2.8-gtk2-unicode-2.8.9.1-fc6_py2.4.i386.rpm (depends on both above)

    Note: the fedora core 6 file were the closest to RHEL 5.5 I could find. Maybe this is already wrong?

    Downloading newest DrPython_3.11.3.zip
    chmoding +x all py, pyw, and the lin file

    $ ./drpython.py
    ./drpython.py: line 44: from: command not found
    

    -> HANGS, have to CTRL+C

    $ ./drpython.pyw
    Traceback (most recent call last):
      File "./drpython.pyw", line 35, in ?
        import drpython
      File "/tmp/DrPython/drpython.py", line 44
        from __future__ import with_statement
    SyntaxError: future feature with_statement is not defined
    
    $ ./drpython.lin
    Traceback (most recent call last):
      File "./drpython.pyw", line 35, in ?
        import drpython
      File "/tmp/DrPython/drpython.py", line 44
        from __future__ import with_statement
    SyntaxError: future feature with_statement is not defined
    

    Any ideas? Should I set up paths or env variables, or is there a basic incompatibilty with those fc6 packets?

    Thanks
    Antares

     
  • Sorry, in last time, with 'with' statement was added. Can you get the code from svn? Then it should work.

     
  • (the import: "from __future__ import with_statement" was added every time, the with statement was used)

     
  • @Antares: Unfortunately your Python version is too old.  The with statement as importable feature from the __future__ was added in Python 2.5.

     
  • David
    David
    2010-09-08

    if i were you, i would use the idle editor and environment that comes with it right out of the box. 

    if you don't like using a mouse to code with (like i prefer), use vi, nvi, or vim.

    python documentation is better than java and C# msdn stuff - at least i think so

    i like to code in all the languages, and think that the IDE's with all the smart logic in the editors are for the less skilled.  and, IMHO, those who rely on them, shouldn't be writing code.

    i think you are trying to put a square peg into a round hole (mixing versions).

    that's enough for me, please pass the album cover…

     
  • Antares
    Antares
    2010-09-08

    thanks, I will try SVN then. And if I have issues, I will see whether I find even older versions packaged for 2.4 and my arch. I let you know how it goes.

    @david: and yes I code myself in vi a lot and can always 'fall back'. Was just curious to try drPython..

     
  • Antares
    Antares
    2010-09-09

    SVN: Is there a particular revision I should check out? The current one (538) produces of course the same error. (The files in the trunk that is)

    Out of curiosity, I also tried ./tags/165/drphython/drpython.pyw:

    Traceback (most recent call last):
      File "./drpython.pyw", line 35, in ?
        import drpython
      File "/root/test/drpython/tags/165/drpython/drpython.py", line 45, in ?
        import wx, wx.stc
      File "/usr/lib/python2.4/site-packages/wx-2.8-gtk2-unicode/wx/__init__.py", line 45, in ?
        from wx._core import *
      File "/usr/lib/python2.4/site-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 4, in ?
        import _core_
    ImportError: /usr/lib/python2.4/site-packages/wx-2.8-gtk2-unicode/wx/_core_.so: wrong ELF class: ELFCLASS32
    
     
  • Maybe that was not pointed out clear enought. Python 2.4 ist not supported anymore with current DrPython, because of the newly introduced "with" statements, and 165 should work. Your error with import _core_ looks strange. I never saw that. Is your wx2.8 working with other wxPython Programs? Demo is working? When you call "python" and then try "import wx", can you import wx?