Hi all, I found a syntax error in scikit learn. This is related to python version 2.4 Compiling /usr/lib/python2.4/site-packages/scikits/learn/utils/arffread.py ... File "/usr/lib/python2.4/site-packages/scikits/learn/utils/arffread.py", line 401 finally: SyntaxError: invalid syntax Nils
Hi, This is a syntax introducted in Python 2.5, so Python 2.4 is not supported by the scikit. Matthieu 2008/3/16, Nils Wagner <nwagner@iam.uni-stuttgart.de>:
Hi all,
I found a syntax error in scikit learn. This is related to python version 2.4
Compiling /usr/lib/python2.4/site-packages/scikits/learn/utils/arffread.py ... File "/usr/lib/python2.4/site-packages/scikits/learn/utils/arffread.py", line 401 finally:
SyntaxError: invalid syntax
Nils
_______________________________________________ Scipy-dev mailing list Scipy-dev@scipy.org http://projects.scipy.org/mailman/listinfo/scipy-dev
-- French PhD student Website : http://matthieu-brucher.developpez.com/ Blogs : http://matt.eifelle.com and http://blog.developpez.com/?blog=92 LinkedIn : http://www.linkedin.com/in/matthieubrucher
Hi, This should be reported as a bug as should any Python 2.4 version code because neither NumPy nor SciPy require only a 2.5 series of Python: The SciPy FAQ (http://www.scipy.org/FAQ) page states that NumPy requires Python 2.3.x or 2.4.x or 2.5.x SciPy General building instructions: http://www.scipy.org/Installing_SciPy/BuildingGeneral - To build SciPy, Python version 2.3 or newer is required. Sure, I know that the Python 2.3 is about 4 years old (2.3.4 released May 2004) but some long terms stability distros (like Centos 4) may not updated Python to even Python 2.4 let alone Python 2.5. I understand that scikits are somewhat special so the requirements of a scikit need to be clearly stated and the scikit should exit if an inappropriate version of Python is used. Note this type of check is going to be essential for Python 2.6 (Python 2.6a1 Released: February 29th 2008) and Python 3.0 (Python 3.0a3 Release: February 29th 2008) because Python 3.0 will break backwards compatibility. Regards Bruce Matthieu Brucher wrote:
Hi,
This is a syntax introducted in Python 2.5, so Python 2.4 is not supported by the scikit.
Matthieu
2008/3/16, Nils Wagner <nwagner@iam.uni-stuttgart.de <mailto:nwagner@iam.uni-stuttgart.de>>:
Hi all,
I found a syntax error in scikit learn. This is related to python version 2.4
Compiling /usr/lib/python2.4/site-packages/scikits/learn/utils/arffread.py ... File "/usr/lib/python2.4/site-packages/scikits/learn/utils/arffread.py", line 401 finally:
SyntaxError: invalid syntax
Nils
_______________________________________________ Scipy-dev mailing list Scipy-dev@scipy.org <mailto:Scipy-dev@scipy.org> http://projects.scipy.org/mailman/listinfo/scipy-dev
-- French PhD student Website : http://matthieu-brucher.developpez.com/ Blogs : http://matt.eifelle.com and http://blog.developpez.com/?blog=92 LinkedIn : http://www.linkedin.com/in/matthieubrucher ------------------------------------------------------------------------
_______________________________________________ Scipy-dev mailing list Scipy-dev@scipy.org http://projects.scipy.org/mailman/listinfo/scipy-dev
On Mon, Mar 17, 2008 at 3:33 PM, Bruce Southey <bsouthey@gmail.com> wrote:
This should be reported as a bug as should any Python 2.4 version code because neither NumPy nor SciPy require only a 2.5 series of Python:
The SciPy FAQ (http://www.scipy.org/FAQ) page states that NumPy requires Python 2.3.x or 2.4.x or 2.5.x SciPy General building instructions: http://www.scipy.org/Installing_SciPy/BuildingGeneral - To build SciPy, Python version 2.3 or newer is required.
NumPy requires >= 2.3 and SciPy >= 2.4. There is currently no guideline for the scikits, and their authors decide for themselves. Interestingly, ipython will soon move to 2.5 and make use of the 'with' statement to grab code blocks. Cheers Stéfan
Bruce Southey wrote:
I understand that scikits are somewhat special so the requirements of a scikit need to be clearly stated and the scikit should exit if an inappropriate version of Python is used. Note this type of check is going to be essential for Python 2.6 (Python 2.6a1 Released: February 29th 2008) and Python 3.0 (Python 3.0a3 Release: February 29th 2008) because Python 3.0 will break backwards compatibility.
I don't know about the general policy for scikits, but in the present case, it was just because I was not aware the try/except/finally construction was python 2.5 specific. Generally, I did not work on scikits.learn for the last 6 months because of my work on numscons (there is a limit on what I can do besides my PhD :) ), sorry about that. Since numscons starts being in good shape, I hope to be back on scikits soon (there will be a scipy/numpy meeting with other scipy/numpy people in a few weeks, and scikits.learn will be one of the main topic for sure) cheers, David
participants (5)
-
Bruce Southey
-
David Cournapeau
-
Matthieu Brucher
-
Nils Wagner
-
Stéfan van der Walt