Gentoo Archives: gentoo-user

From: William Kenworthy <billk@×××××××××.au>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] ceph and a possible python problem
Date: Fri, 16 Aug 2013 14:31:58
Message-Id: 520E37C9.6090801@iinet.net.au
In Reply to: Re: [gentoo-user] ceph and a possible python problem by "Canek Peláez Valdés"
1 On 16/08/13 22:15, Canek Peláez Valdés wrote:
2 > On Fri, Aug 16, 2013 at 9:12 AM, William Kenworthy <billk@×××××××××.au> wrote:
3 >> On 16/08/13 15:34, Keith Dart wrote:
4 >>> Re , William Kenworthy said:
5 >>>> olympus ~ # ceph
6 >>>> File "/usr/bin/ceph", line 192
7 >>>> print '\n', s, '\n', '=' * len(s)
8 >>>> ^
9 >>>> SyntaxError: invalid syntax
10 >>>> olympus ~ #
11 >>>
12 >>>
13 >>> In Python 3 "print" is a function, and should be called like this:
14 >>>
15 >>> print('\n', s, '\n', '=' * len(s))
16 >>>
17 >>> This works as-is in Python 2, unless you have this at the top of the
18 >>> file:
19 >>>
20 >>> from __future__ import print_function
21 >>>
22 >>>
23 >>> -- Keith
24 >>>
25 >>>
26 >> Thanks Keith, that was suggested on the ceph list but grepping doesnt
27 >> show it in the source. With this version of ceph they have replaced the
28 >> "ceph" binary with a python script so its quite different from the older
29 >> version which works. They target mainly centos and ubuntu/debian so I
30 >> will have to keep looking.
31 >
32 > Have you tried a simple:
33 >
34 > python3 /usr/bin/ceph
35 >
36 > Regards.
37 >
38
39 No, doesnt work either. The ceph guys say it works fine for them which
40 leaves me suspecting something is broken on my system ...
41
42 BillK

Replies

Subject Author
Re: [gentoo-user] ceph and a possible python problem William Kenworthy <billk@×××××××××.au>