Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 374293

Summary: net-mail/mailman ebuild depends on python 2
Product: Gentoo Linux Reporter: Jack Eids_no_google_me_ness <jack>
Component: New packagesAssignee: Hanno Böck <hanno>
Status: RESOLVED DUPLICATE    
Severity: minor CC: daniel, jdavid.ibp, net-mail+disabled
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: mailman ebuild that works when Python default is 3
Updated ebuild for 2.1.14 version (based on /usr/portage/net-mail/mailman files)

Description Jack Eids_no_google_me_ness 2011-07-07 01:13:48 UTC
This forum poster and I apparently have had the same problem after trying to eselect python 3.
http://forums.gentoo.org/viewtopic-p-6700031.html

eselecting python 2 is a suitable workaround, but if we could get the dependency and shebangs nailed down, it would be nice.

Reproducible: Always

Steps to Reproduce:
1. install mailman
2. eselect python with version 3, or install only python 3 (if that's even possible)
3. /etc/init.d/mailman start
Actual Results:  
mailman fails to start. attempt to start manually produces this:

bin/mailmanctl -s start
File "bin/mailmanctl", line 149
except (IOError, ValueError), e:
^
SyntaxError: invalid syntax

Expected Results:  
I'd like it to automatically use python 2.
Comment 1 Ian Delaney (RETIRED) gentoo-dev 2011-11-07 13:14:34 UTC
I get it not starting with both 2.7 & 3.1
You have not stipulated which version of mailman. The one I have emerged has no exes in /bin. they are all in /usr/lib64/mailman/bin/
Comment 2 Juan David Ibáñez Palomar 2012-04-22 17:43:26 UTC
I have the same problem. I have rented a server with a bare Gentoo
pre-installed, it has Python 3 as the default. When emerging mailman
2.1.14 I get many syntax errors, though it emerges anyway. Then :

mailman@foobar ~ $ ./bin/mailmanctl -s start
  File "./bin/mailmanctl", line 149
    except (IOError, ValueError), e:
                                ^
SyntaxError: invalid syntax
Comment 3 Juan David Ibáñez Palomar 2012-05-04 18:09:08 UTC
Created attachment 310793 [details]
mailman ebuild that works when Python default is 3

Available in this overlay :

  https://github.com/hforge/overlay
Comment 4 Heavenly Avenger 2012-06-17 05:42:50 UTC
I confirm this bug to be happening:


mailman@ethereal ~ $ bin/mailmanctl -s start
  File "bin/mailmanctl", line 149
    except (IOError, ValueError), e:
                                ^
SyntaxError: invalid syntax
mailman@ethereal ~ $ logout
ethereal layman # eselect python list
Available Python interpreters:
  [1]   python2.7
  [2]   python3.2 *
ethereal layman #

profile:
  [9]   hardened/linux/amd64 *
Comment 5 Heavenly Avenger 2012-06-17 06:18:25 UTC
Created attachment 315565 [details]
Updated ebuild for 2.1.14 version (based on /usr/portage/net-mail/mailman files)

Here is an updated ebuild. I've just installed it here naming it as staging/mailman-2.1.14, copied the needed files from /usr/portage/net-mail/mailman/files (all files pointed by ${FILESDIR} in the ebuild file) and voila, it works!. No more syntax errors out of the blue.
Comment 6 Hanno Böck gentoo-dev 2012-08-08 17:31:42 UTC

*** This bug has been marked as a duplicate of bug 315335 ***