Welcome! Log In Create A New Profile

Advanced

Python will not run SyntaxError: future feature absolute_import is not defined

Posted by sheep 
Python will not run SyntaxError: future feature absolute_import is not defined
February 07, 2010 12:52AM
After a year of collecting parts to convert my CNC into a repstrap I finally downloaded skienforge.

I am running OSX, I do have some tools installed so I can run gerbv.

I am not running from the X11 shell, just terminal.

First I checked the python version
$ python -V
Python 2.3.5
$

the website says 2.x so this should be good

next it did
$ locate Tkinter
/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/lib-tk/Tkinter.py
/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/lib-tk/Tkinter.pyc
/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/lib-tk/Tkinter.pyo
/Volumes/Fantine/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/lib-tk/Tkinter.py
/Volumes/Fantine/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/lib-tk/Tkinter.pyc
/Volumes/Fantine/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/lib-tk/Tkinter.pyo

so this looks good

I downloaded from [members.axion.net]

this was unzipped into
~/aaa/reprap_python_beanshell

when I tried to run this the following happened

$ python skeinforge.py
File "skeinforge.py", line 197
from __future__ import absolute_import
SyntaxError: future feature absolute_import is not defined


I then tried

$ python
Python 2.3.5 (#1, Jan 12 2009, 14:43:55)
[GCC 3.3 20030304 (Apple Computer, Inc. build 1819)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import skeinforge.py
Traceback (most recent call last):
File "", line 1, in ?
File "skeinforge.py", line 197
from __future__ import absolute_import
SyntaxError: future feature absolute_import is not defined
>>> skieinforge.main()
Traceback (most recent call last):
File "", line 1, in ?
NameError: name 'skieinforge' is not defined
>>> ^D


At the moment I am busy working on the firmware side of things, So I do not have much time to fiddle with the host side. I was able to get the JAVA host to run inside the netbeans IDE. That mostly works.

I was wanting to run something I can browse about with.


There really needs to be a simpler one click solution on the host side.


-julie
Re: Python will not run SyntaxError: future feature absolute_import is not defined
February 07, 2010 07:02AM
Looks like it actually needs Python 2.5 or later: [docs.python.org]


[www.hydraraptor.blogspot.com]
Re: Python will not run SyntaxError: future feature absolute_import is not defined
February 07, 2010 02:33PM
Someone needs to update the wiki and blogs then.

A check of macports indicates that on Tiger, the default 2.3 is installed, Leopard uses 2.5 as default.

What a mess. That even though one has a UNIX core, to force the users to upgrade to more expensive hardware, just to sell it.


Sorry for the MINI rant, but if reprap is to fulfill the vision of re-cycle/re-use and the accessibility to anyone in the world, then there needs to be simple one click solutions that work with legacy hardware.

This is the goal of the firmware I am writing.

Sure, there is no glamor developing for obsolescence, But that is what attracted be to reprap. A strike against this waste. I have at least 6 laptops, the oldest a mac portable (luggable) is a museum piece. The newest is a 1.25 G4. (There is are some windows 98 and XP systems there too.) This is capable hardware, why is there no toolchain to make it work? end of mini rant.

-julie
Re: Python will not run SyntaxError: future feature absolute_import is not defined
February 07, 2010 03:39PM
You don't need a new OS or hardware you just need to download a new Python from ActiveState. No big deal, I use 2.6.


[www.hydraraptor.blogspot.com]
Re: Python will not run SyntaxError: future feature absolute_import is not defined
February 07, 2010 07:27PM
julie,

if your commercial OS is causing you so many issues, install linux tongue sticking out smiley


-----------------------------------------------
Wooden Mendel
Teacup Firmware
Re: Python will not run SyntaxError: future feature absolute_import is not defined
February 08, 2010 12:53AM
Success!

macports did install python2.6. I had to run it from the X11 term. Finally I got some dialogs.

Some searching through the python docs and a few search terms located a page explaining the problem

Is there a jog/feedback window, so interaction with my firmware can be tested?
Sorry, only registered users may post in this forum.

Click here to login