Gentoo Archives: gentoo-user

From: "Canek Peláez Valdés" <caneko@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] ceph and a possible python problem
Date: Fri, 16 Aug 2013 14:15:18
Message-Id: CADPrc83gFWDNr+n9qcwBY5D06m3HJKF8HhRfsc4HvQvXH0sOVA@mail.gmail.com
In Reply to: Re: [gentoo-user] ceph and a possible python problem by William Kenworthy
1 On Fri, Aug 16, 2013 at 9:12 AM, William Kenworthy <billk@×××××××××.au> wrote:
2 > On 16/08/13 15:34, Keith Dart wrote:
3 >> Re , William Kenworthy said:
4 >>> olympus ~ # ceph
5 >>> File "/usr/bin/ceph", line 192
6 >>> print '\n', s, '\n', '=' * len(s)
7 >>> ^
8 >>> SyntaxError: invalid syntax
9 >>> olympus ~ #
10 >>
11 >>
12 >> In Python 3 "print" is a function, and should be called like this:
13 >>
14 >> print('\n', s, '\n', '=' * len(s))
15 >>
16 >> This works as-is in Python 2, unless you have this at the top of the
17 >> file:
18 >>
19 >> from __future__ import print_function
20 >>
21 >>
22 >> -- Keith
23 >>
24 >>
25 > Thanks Keith, that was suggested on the ceph list but grepping doesnt
26 > show it in the source. With this version of ceph they have replaced the
27 > "ceph" binary with a python script so its quite different from the older
28 > version which works. They target mainly centos and ubuntu/debian so I
29 > will have to keep looking.
30
31 Have you tried a simple:
32
33 python3 /usr/bin/ceph
34
35 Regards.
36 --
37 Canek Peláez Valdés
38 Posgrado en Ciencia e Ingeniería de la Computación
39 Universidad Nacional Autónoma de México

Replies

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