Installation Fails #10

Closed
justdan96 opened this Issue Jan 10, 2012 · 5 comments

Comments

Projects
None yet
3 participants

Installing on CentOS 5.6, installation fails:

[root@cam-rpmbuild ianweller-mw-40ecd66]# python setup.py install
running install
running build
running build_py
creating build
creating build/lib
creating build/lib/mw
copying src/mw/metadir.py -> build/lib/mw
copying src/mw/init.py -> build/lib/mw
copying src/mw/cli.py -> build/lib/mw
copying src/mw/clicommands.py -> build/lib/mw
running build_scripts
creating build/scripts-2.4
copying and adjusting bin/mw -> build/scripts-2.4
changing mode of build/scripts-2.4/mw from 644 to 755
running install_lib
creating /usr/lib/python2.4/site-packages/mw
copying build/lib/mw/metadir.py -> /usr/lib/python2.4/site-packages/mw
copying build/lib/mw/init.py -> /usr/lib/python2.4/site-packages/mw
copying build/lib/mw/cli.py -> /usr/lib/python2.4/site-packages/mw
copying build/lib/mw/clicommands.py -> /usr/lib/python2.4/site-packages/mw
byte-compiling /usr/lib/python2.4/site-packages/mw/metadir.py to metadir.pyc
File "/usr/lib/python2.4/site-packages/mw/metadir.py", line 52
with open(self.config_loc, 'wb') as config_file:
^
SyntaxError: invalid syntax
byte-compiling /usr/lib/python2.4/site-packages/mw/init.py to init.pyc
byte-compiling /usr/lib/python2.4/site-packages/mw/cli.py to cli.pyc
byte-compiling /usr/lib/python2.4/site-packages/mw/clicommands.py to clicommands.pyc
File "/usr/lib/python2.4/site-packages/mw/clicommands.py", line 229
with file(full_filename, 'w') as fd:
^
SyntaxError: invalid syntax
running install_scripts
copying build/scripts-2.4/mw -> /usr/bin
changing mode of /usr/bin/mw to 755
[root@cam-rpmbuild ianweller-mw-40ecd66]# /usr/bin/mw
mw mwm
[root@cam-rpmbuild ianweller-mw-40ecd66]# /usr/bin/mw
Traceback (most recent call last):
File "/usr/bin/mw", line 21, in ?
from mw import cli
File "/usr/lib/python2.4/site-packages/mw/cli.py", line 19, in ?
import mw.clicommands
File "/usr/lib/python2.4/site-packages/mw/clicommands.py", line 229
with file(full_filename, 'w') as fd:
^
SyntaxError: invalid syntax
[root@cam-rpmbuild ianweller-mw-40ecd66]#

Collaborator

reagle commented Jan 10, 2012

I don't know about setup.py ... but it won't run with Python 2.4 in any case as with is a 2.5 construct.

Owner

ilianaw commented Jan 10, 2012

I don't think I want to bother with supporting Python 2.4. Sorry.

Thank you, I installed python26 and the setup ran fine, now I get another error running the program:

root@cam-rpmbuild bzr-2.0.5]# mw
Traceback (most recent call last):
File "/usr/bin/mw", line 21, in
from mw import cli
File "/usr/lib/python2.6/site-packages/mw/cli.py", line 19, in
import mw.clicommands
File "/usr/lib/python2.6/site-packages/mw/clicommands.py", line 23, in
import mw.metadir
File "/usr/lib/python2.6/site-packages/mw/metadir.py", line 19, in
import bzrlib.diff
ImportError: No module named bzrlib.diff
[root@cam-rpmbuild bzr-2.0.5]# python26 /usr/bin/mw
Traceback (most recent call last):
File "/usr/bin/mw", line 21, in
from mw import cli
File "/usr/lib/python2.6/site-packages/mw/cli.py", line 19, in
import mw.clicommands
File "/usr/lib/python2.6/site-packages/mw/clicommands.py", line 23, in
import mw.metadir
File "/usr/lib/python2.6/site-packages/mw/metadir.py", line 19, in
import bzrlib.diff
ImportError: No module named bzrlib.diff
[root@cam-rpmbuild bzr-2.0.5]#

I installed bzr 2.0.5 from source but the errors persist.

Edit: I also installed the following, from a Google search entry: yum -y install bzr bzrtools bzr-gtk olive

Collaborator

reagle commented Jan 10, 2012

On Tuesday, January 10, 2012, Daniel J. Bryant wrote:

I installed bzr 2.0.5 from source but the errors persist.

I'm using Ubuntu and installed python-bzrlib for the dependency, don't know about CentOS.

Okay, it was issues with having Python 2.4 and 2.6 installed.
I installed the latest version of bzr available from yum for EL5 - which gets installed in /usr/lib64/python2.4. I had to copy these files to the 2.6 directory, then install setuptools, kitchen and simplemediawiki using the python26 binary. After that it all worked brilliantly.

justdan96 closed this Jan 11, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment