You are not logged in.

#101 2010-10-22 22:51:16

youri
Member
From: southern ohio
Registered: 2009-05-22
Posts: 26

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

I've been trying to make deluge (most of the dependencies are related to it) work with python3 but all it does is give me errors. Guess I'll have to live with two conflicting python versions.

Offline

#102 2010-10-22 23:24:54

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

They're not conflicting - if they were, you couldn't have them both installed.

Offline

#103 2010-10-22 23:58:43

moravec
Member
Registered: 2010-10-22
Posts: 2

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Isn't there supposed to be a python script 2to3.py.  to convert python 2 programs to python 3?  I can't find it.  It was supposed to be installed under the Tools/scripts directory which was not created during the install.

Offline

#104 2010-10-23 00:32:22

Allan
is always right
From: Brisbane, AU
Registered: 2007-06-09
Posts: 10,467
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

> pacman -Qo 2to3 
/usr/bin/2to3 is owned by python2 2.7-2

and it only does part of the job for you...

Offline

#105 2010-10-23 01:54:55

anonymous_user
Member
Registered: 2009-08-28
Posts: 3,058

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

youri wrote:

Because, what is the point of having two pythons on my system? Feels like bloat.

I did the opposite and removed python (v3). I seem to have no apps that depend on it so why not.

Offline

#106 2010-10-23 07:36:01

azleifel
Member
Registered: 2007-10-28
Posts: 476

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Smooth update.  Just needed to amend four AUR packages and then uninstall python 3.

Offline

#107 2010-10-23 11:03:02

crocowhile
Member
Registered: 2009-10-18
Posts: 55

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Any idea on how to fix python-nautilus? It won't even install.

Offline

#108 2010-10-23 11:29:03

Foucault
Member
From: Athens, Greece
Registered: 2010-04-06
Posts: 209

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Try adding

export PYTHON=python2

in the PKGBUILD just before the ./configure step

Offline

#109 2010-10-23 12:55:58

crocowhile
Member
Registered: 2009-10-18
Posts: 55

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Thank you Foucault. Installation worked but I am not sure python extensions actually do: at least rabbitvcs-nautilus does not hmm

Offline

#110 2010-10-23 16:25:17

moravec
Member
Registered: 2010-10-22
Posts: 2

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Thanks Allan found 2to3.  So far not impressed.

Offline

#111 2010-10-23 22:05:37

Allan
is always right
From: Brisbane, AU
Registered: 2007-06-09
Posts: 10,467
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

moravec wrote:

Thanks Allan found 2to3.  So far not impressed.

It is not a magic bullet...

First you need to run your application using a flag to warn about python3 incompatibilities/deprecations and fix all those.  The you can use 2to3.  The first bit is what takes all the time.  And I'm guessing that does not touch C code at all...

Offline

#112 2010-10-24 09:09:17

Cobra78
Member
From: Ravenna
Registered: 2010-08-12
Posts: 1

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

My mistake, sorry.

Last edited by Cobra78 (2010-10-24 09:10:11)


Dell Inspiron 1720 Ice White Windows 7 Pro/Archlinux x86_64 - 2.6.35.x
Msi Wind U100 Windows Xp/Ubuntu netbook Remix 10.04

Offline

#113 2010-10-24 10:21:14

Barghest
Member
From: Hanau/Germany
Registered: 2008-01-03
Posts: 563

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Anyone already has a script to change the first line for python2 apps?

Crossover Linux needs python2 and it has a bunch of python files lying in different folders. I now need to change the python to python2 in each file what costs a lot of time.

Offline

#114 2010-10-24 17:03:44

unhammer
Member
Registered: 2009-10-01
Posts: 97
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Barghest wrote:

Anyone already has a script to change the first line for python2 apps?

Crossover Linux needs python2 and it has a bunch of python files lying in different folders. I now need to change the python to python2 in each file what costs a lot of time.

See http://allanmcrae.com/2010/10/big-pytho … rch-linux/ , there is a sed command for that.

Offline

#115 2010-10-24 18:54:32

kvn
Member
Registered: 2010-08-13
Posts: 12

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

bond wrote:

I'm having a bit of trouble with flexget (http://flexget.com/)

$ svn co http://svn.flexget.com/trunk flexget-dev
#modify binding
$ nano flexget-dev/bootstrap.py
$ python2 flexget-dev/bootstrap.py

Results in lots of import errors
or attempting the .egg;

$ wget http://download.flexget.com/unstable/Fl … -py2.6.egg -p /tmp
$ sudo easy_install-2.7 /tmp/FlexGet-1.0r1532-py2.6.egg

#Generate paver-minilib.zip
#OSError: [Errno 20] Not a directory: 'paver-minilib.zip/paver/__init__.py'

any tips?

sudo easy_install pip
sudo pip install flexget

after that, it might work. i'm having issues with the transmissionrpc/backlog/sqlalchemy plugin from working after though. I've created a ticket here

http://flexget.com/ticket/757

Offline

#116 2010-10-25 03:44:50

k3ttc4r
Member
From: around somewhere
Registered: 2008-12-28
Posts: 137
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

kvn wrote:

sudo easy_install pip
sudo pip install flexget

You're my savior! I also had to delete the database, but now it works fine again.


arch64   ||   github | dotshare | blog

Offline

#117 2010-10-25 08:44:53

bananaoomarang
Member
From: England
Registered: 2009-10-29
Posts: 179
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

It seems to be pretty smooth here but it does seem to have broken a few things on the AUR, even replacing python commands with python2 ones in the PKGBUILD. I can't blame the devs for that though, the AUR will just take a while to adjust.

Offline

#118 2010-10-25 09:19:08

fixu
Member
Registered: 2008-05-29
Posts: 27

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

hi,

i got a problem with hsoconnect. if i try to launch it, i get the following error message:

File "/usr/share/hsoconnect/hsoc/HSOconnect.py", line 46
    except os.error, args:
                   ^
SyntaxError: invalid syntax


maybe it is easy to fix it, but i have no idea about python.

some ideas?

cheers

felix

Offline

#119 2010-10-25 09:24:05

linux-ka
Member
From: ADL
Registered: 2010-05-07
Posts: 232

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

have a look at the shebang...

Offline

#120 2010-10-25 10:59:08

Mr.Elendig
#archlinux@freenode channel op
From: The intertubes
Registered: 2004-11-07
Posts: 3,769

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

fixu wrote:

hi,

i got a problem with hsoconnect. if i try to launch it, i get the following error message:

File "/usr/share/hsoconnect/hsoc/HSOconnect.py", line 46
    except os.error, args:
                   ^
SyntaxError: invalid syntax


maybe it is easy to fix it, but i have no idea about python.

some ideas?

cheers

felix

-Syu, hsoconnect have been rebuilt against python2

If you do have the latest version (1.2.18-6) and it sill fails, then make a bug report.

Last edited by Mr.Elendig (2010-10-25 11:00:42)


Evil #archlinux@freenode channel op and general support dude.
. files on github, Screenshots, Random pics and the rest

Offline

#121 2010-10-25 11:02:42

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,937
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?


Give what you have. To someone, it may be better than you dare to think.
Blog

Offline

#122 2010-10-25 12:08:49

fixu
Member
Registered: 2008-05-29
Posts: 27

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Offline

#123 2010-10-25 12:32:00

scrawl
Member
Registered: 2010-01-14
Posts: 44

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

Update sucked a lot for me.. I don't know why but pacman didnt like me. First everything seemed to go smooth but then suddenly half of my system was uninstalled. Couldnt even run pacman anymore because of missing libs. But I fixed that, downloaded libs with w3m so I could use pacman again, then installed all the packages again.

Offline

#124 2010-10-26 15:58:34

mcgrew
Member
Registered: 2010-10-26
Posts: 3

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

python-matplotlib is broken. When I try to run a script I wrote it is looking in python 2.6 site-packages for the font files:

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/matplotlib/backends/backend_gtk.py", line 393, in expose_event
    self._render_figure(self._pixmap, w, h)
  File "/usr/lib/python2.7/site-packages/matplotlib/backends/backend_gtkagg.py", line 75, in _render_figure
    FigureCanvasAgg.draw(self)
  File "/usr/lib/python2.7/site-packages/matplotlib/backends/backend_agg.py", line 394, in draw
    self.figure.draw(self.renderer)
  File "/usr/lib/python2.7/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/matplotlib/figure.py", line 798, in draw
    func(*args)
  File "/usr/lib/python2.7/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/matplotlib/axes.py", line 1934, in draw
    a.draw(renderer)
  File "/usr/lib/python2.7/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/matplotlib/axis.py", line 1017, in draw
    tick.draw(renderer)
  File "/usr/lib/python2.7/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/matplotlib/axis.py", line 234, in draw
    self.label1.draw(renderer)
  File "/usr/lib/python2.7/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/matplotlib/text.py", line 524, in draw
    bbox, info = self._get_layout(renderer)
  File "/usr/lib/python2.7/site-packages/matplotlib/text.py", line 298, in _get_layout
    ismath=False)
  File "/usr/lib/python2.7/site-packages/matplotlib/backends/backend_agg.py", line 180, in get_text_width_height_descent
    font = self._get_agg_font(prop)
  File "/usr/lib/python2.7/site-packages/matplotlib/backends/backend_agg.py", line 221, in _get_agg_font
    font = FT2Font(str(fname))
RuntimeError: Could not open facefile /usr/lib/python2.6/site-packages/matplotlib/mpl-data/fonts/ttf/Vera.ttf; Cannot_Open_Resource

I looked through the matplotlib source and couldn't find any references to 2.6 other than PYVERSION=2.6 in make.osx. Changing that to 2.7 and rebuilding the package didn't help. Any ideas?

Edit:
before anyone suggests it, creating a soft link from /usr/lib/python2.6/site-packages/matplotlib to /usr/lib/python2.7/site-packages/matplotlib fixes the problem, but it's obviously not ideal.

Last edited by mcgrew (2010-10-26 16:07:11)

Offline

#125 2010-10-26 16:18:33

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,937
Website

Re: "Python2 & 3 major rebuild" upgrade - impressions ?

this issue was raised in this thread already if i remember well. <hint> first page, last comment, solution is on second page, first post


Give what you have. To someone, it may be better than you dare to think.
Blog

Offline

Board footer

Powered by FluxBB