File: prettytable

package info (click to toggle)
python-keystoneclient 2012.1-3%2Bdeb7u1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 460 kB
  • sloc: python: 3,174; sh: 113; makefile: 78
file content (27 lines) | stat: -rw-r--r-- 677 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Remove printt

prettyprint 0.6 removed printt at the last minute, replace with get_string

Fixes bug 995811

Change-Id: Iaabe47c1ae9270d9d00f804388a1837767cb20f1

--- a/keystoneclient/utils.py
+++ b/keystoneclient/utils.py
@@ -34,14 +34,14 @@
                 row.append(data)
         pt.add_row(row)
 
-    pt.printt(sortby=fields[0])
+    print pt.get_string(sortby=fields[0])
 
 
 def print_dict(d):
     pt = prettytable.PrettyTable(['Property', 'Value'], caching=False)
     pt.aligns = ['l', 'l']
     [pt.add_row(list(r)) for r in d.iteritems()]
-    pt.printt(sortby='Property')
+    print pt.get_string(sortby='Property')
 
 
 def find_resource(manager, name_or_id):