Merge lp:~cjwatson/storm/py3-print into lp:storm

Proposed by Colin Watson
Status: Merged
Merged at revision: 499
Proposed branch: lp:~cjwatson/storm/py3-print
Merge into: lp:storm
Diff against target: 1080 lines (+165/-23)
72 files modified
NEWS (+1/-1)
setup.py (+3/-0)
storm/__init__.py (+2/-0)
storm/base.py (+2/-0)
storm/cache.py (+2/-0)
storm/compat.py (+2/-0)
storm/database.py (+2/-0)
storm/databases/__init__.py (+2/-0)
storm/databases/postgres.py (+2/-0)
storm/databases/sqlite.py (+2/-0)
storm/event.py (+2/-0)
storm/exceptions.py (+2/-0)
storm/expr.py (+2/-0)
storm/info.py (+2/-0)
storm/locals.py (+2/-0)
storm/properties.py (+2/-0)
storm/references.py (+2/-0)
storm/schema/__init__.py (+2/-0)
storm/schema/patch.py (+4/-2)
storm/schema/schema.py (+3/-1)
storm/schema/sharding.py (+2/-0)
storm/sqlobject.py (+2/-0)
storm/store.py (+3/-1)
storm/testing.py (+3/-1)
storm/tracer.py (+2/-0)
storm/twisted/testing.py (+2/-0)
storm/twisted/transact.py (+2/-0)
storm/tz.py (+2/-0)
storm/uri.py (+2/-0)
storm/variables.py (+2/-0)
storm/wsgi.py (+2/-0)
storm/xid.py (+2/-0)
storm/zope/__init__.py (+2/-0)
storm/zope/adapters.py (+2/-0)
storm/zope/interfaces.py (+2/-0)
storm/zope/metaconfigure.py (+2/-0)
storm/zope/metadirectives.py (+2/-0)
storm/zope/schema.py (+2/-0)
storm/zope/testing.py (+2/-0)
storm/zope/zstorm.py (+2/-0)
tests/__init__.py (+3/-0)
tests/base.py (+2/-0)
tests/cache.py (+2/-0)
tests/database.py (+2/-0)
tests/databases/base.py (+2/-0)
tests/databases/postgres.py (+2/-0)
tests/databases/proxy.py (+2/-0)
tests/databases/sqlite.py (+2/-0)
tests/event.py (+2/-0)
tests/expr.py (+2/-0)
tests/helper.py (+2/-0)
tests/info.py (+2/-0)
tests/mocker.py (+2/-0)
tests/properties.py (+2/-0)
tests/schema/patch.py (+2/-0)
tests/schema/schema.py (+2/-0)
tests/schema/sharding.py (+2/-0)
tests/sqlobject.py (+2/-0)
tests/store/base.py (+2/-0)
tests/store/postgres.py (+2/-0)
tests/store/sqlite.py (+2/-0)
tests/tracer.py (+2/-0)
tests/tutorial.txt (+17/-17)
tests/twisted/__init__.py (+2/-0)
tests/twisted/transact.py (+2/-0)
tests/uri.py (+2/-0)
tests/variables.py (+2/-0)
tests/wsgi.py (+2/-0)
tests/zope/__init__.py (+2/-0)
tests/zope/adapters.py (+2/-0)
tests/zope/testing.py (+2/-0)
tests/zope/zstorm.py (+2/-0)
To merge this branch: bzr merge lp:~cjwatson/storm/py3-print
Reviewer Review Type Date Requested Status
Simon Poirier (community) Approve
Review via email: mp+368385@code.launchpad.net

Commit message

Use Python 3-style print functions.

Description of the change

I added "from __future__ import print_function" to all non-trivial .py files in the hope of ensuring that none creep back in before the port is finished.

To post a comment you must log in.
Revision history for this message
Simon Poirier (simpoir) wrote :

+1 LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'NEWS'
2--- NEWS 2019-06-03 08:45:24 +0000
3+++ NEWS 2019-06-05 11:42:41 +0000
4@@ -35,7 +35,7 @@
5 with CaptureTracer() as tracer:
6 # Run queries
7 pass
8- print tracer.queries # Print all queries run in the context manager block
9+ print(tracer.queries) # Print all queries run in the context manager block
10
11 You will need the python-fixtures package in order to use this feature.
12
13
14=== modified file 'setup.py'
15--- setup.py 2019-06-05 10:41:32 +0000
16+++ setup.py 2019-06-05 11:42:41 +0000
17@@ -1,4 +1,7 @@
18 #!/usr/bin/env python
19+
20+from __future__ import print_function
21+
22 import os
23 import re
24
25
26=== modified file 'storm/__init__.py'
27--- storm/__init__.py 2019-05-30 13:39:54 +0000
28+++ storm/__init__.py 2019-06-05 11:42:41 +0000
29@@ -19,6 +19,8 @@
30 # along with this program. If not, see <http://www.gnu.org/licenses/>.
31 #
32
33+from __future__ import print_function
34+
35 import os
36
37
38
39=== modified file 'storm/base.py'
40--- storm/base.py 2007-07-05 20:29:25 +0000
41+++ storm/base.py 2019-06-05 11:42:41 +0000
42@@ -18,6 +18,8 @@
43 # You should have received a copy of the GNU Lesser General Public License
44 # along with this program. If not, see <http://www.gnu.org/licenses/>.
45 #
46+from __future__ import print_function
47+
48 from storm.properties import PropertyPublisherMeta
49
50
51
52=== modified file 'storm/cache.py'
53--- storm/cache.py 2009-02-16 10:44:31 +0000
54+++ storm/cache.py 2019-06-05 11:42:41 +0000
55@@ -1,3 +1,5 @@
56+from __future__ import print_function
57+
58 import itertools
59
60
61
62=== modified file 'storm/compat.py'
63--- storm/compat.py 2019-06-03 08:45:24 +0000
64+++ storm/compat.py 2019-06-05 11:42:41 +0000
65@@ -19,6 +19,8 @@
66 # along with this program. If not, see <http://www.gnu.org/licenses/>.
67 #
68
69+from __future__ import print_function
70+
71 __all__ = ["json"]
72
73
74
75=== modified file 'storm/database.py'
76--- storm/database.py 2019-05-30 13:39:54 +0000
77+++ storm/database.py 2019-06-05 11:42:41 +0000
78@@ -25,6 +25,8 @@
79 supported in modules in L{storm.databases}.
80 """
81
82+from __future__ import print_function
83+
84 from storm.expr import Expr, State, compile
85 # Circular import: imported at the end of the module.
86 # from storm.tracer import trace
87
88=== modified file 'storm/databases/__init__.py'
89--- storm/databases/__init__.py 2007-08-07 18:36:04 +0000
90+++ storm/databases/__init__.py 2019-06-05 11:42:41 +0000
91@@ -19,6 +19,8 @@
92 # along with this program. If not, see <http://www.gnu.org/licenses/>.
93 #
94
95+from __future__ import print_function
96+
97
98 class Dummy(object):
99 """Magic "infectious" class.
100
101=== modified file 'storm/databases/postgres.py'
102--- storm/databases/postgres.py 2019-06-05 09:56:39 +0000
103+++ storm/databases/postgres.py 2019-06-05 11:42:41 +0000
104@@ -19,6 +19,8 @@
105 # along with this program. If not, see <http://www.gnu.org/licenses/>.
106 #
107
108+from __future__ import print_function
109+
110 from datetime import datetime, date, time, timedelta
111 import json
112
113
114=== modified file 'storm/databases/sqlite.py'
115--- storm/databases/sqlite.py 2019-05-30 13:39:54 +0000
116+++ storm/databases/sqlite.py 2019-06-05 11:42:41 +0000
117@@ -18,6 +18,8 @@
118 # You should have received a copy of the GNU Lesser General Public License
119 # along with this program. If not, see <http://www.gnu.org/licenses/>.
120 #
121+from __future__ import print_function
122+
123 from datetime import datetime, date, time, timedelta
124 from time import sleep, time as now
125 import sys
126
127=== modified file 'storm/event.py'
128--- storm/event.py 2008-06-18 21:51:12 +0000
129+++ storm/event.py 2019-06-05 11:42:41 +0000
130@@ -18,6 +18,8 @@
131 # You should have received a copy of the GNU Lesser General Public License
132 # along with this program. If not, see <http://www.gnu.org/licenses/>.
133 #
134+from __future__ import print_function
135+
136 import weakref
137
138 from storm import has_cextensions
139
140=== modified file 'storm/exceptions.py'
141--- storm/exceptions.py 2015-11-23 15:03:53 +0000
142+++ storm/exceptions.py 2019-06-05 11:42:41 +0000
143@@ -18,6 +18,8 @@
144 # You should have received a copy of the GNU Lesser General Public License
145 # along with this program. If not, see <http://www.gnu.org/licenses/>.
146 #
147+from __future__ import print_function
148+
149 from abc import ABCMeta
150 import types
151
152
153=== modified file 'storm/expr.py'
154--- storm/expr.py 2019-06-05 10:41:32 +0000
155+++ storm/expr.py 2019-06-05 11:42:41 +0000
156@@ -18,6 +18,8 @@
157 # You should have received a copy of the GNU Lesser General Public License
158 # along with this program. If not, see <http://www.gnu.org/licenses/>.
159 #
160+from __future__ import print_function
161+
162 from decimal import Decimal
163 from datetime import datetime, date, time, timedelta
164 from weakref import WeakKeyDictionary
165
166=== modified file 'storm/info.py'
167--- storm/info.py 2011-08-14 08:55:15 +0000
168+++ storm/info.py 2019-06-05 11:42:41 +0000
169@@ -18,6 +18,8 @@
170 # You should have received a copy of the GNU Lesser General Public License
171 # along with this program. If not, see <http://www.gnu.org/licenses/>.
172 #
173+from __future__ import print_function
174+
175 from weakref import ref
176
177 from storm.exceptions import ClassInfoError
178
179=== modified file 'storm/locals.py'
180--- storm/locals.py 2012-03-01 13:28:26 +0000
181+++ storm/locals.py 2019-06-05 11:42:41 +0000
182@@ -18,6 +18,8 @@
183 # You should have received a copy of the GNU Lesser General Public License
184 # along with this program. If not, see <http://www.gnu.org/licenses/>.
185 #
186+from __future__ import print_function
187+
188 from storm.properties import Bool, Int, Float, RawStr, Chars, Unicode
189 from storm.properties import List, Decimal, DateTime, Date, Time, Enum, UUID
190 from storm.properties import TimeDelta, Pickle, JSON
191
192=== modified file 'storm/properties.py'
193--- storm/properties.py 2011-02-28 21:16:29 +0000
194+++ storm/properties.py 2019-06-05 11:42:41 +0000
195@@ -18,6 +18,8 @@
196 # You should have received a copy of the GNU Lesser General Public License
197 # along with this program. If not, see <http://www.gnu.org/licenses/>.
198 #
199+from __future__ import print_function
200+
201 from bisect import insort_left, bisect_left
202 import weakref
203 import sys
204
205=== modified file 'storm/references.py'
206--- storm/references.py 2013-06-28 08:13:08 +0000
207+++ storm/references.py 2019-06-05 11:42:41 +0000
208@@ -18,6 +18,8 @@
209 # You should have received a copy of the GNU Lesser General Public License
210 # along with this program. If not, see <http://www.gnu.org/licenses/>.
211 #
212+from __future__ import print_function
213+
214 import weakref
215
216 from storm.exceptions import (
217
218=== modified file 'storm/schema/__init__.py'
219--- storm/schema/__init__.py 2014-11-18 19:38:53 +0000
220+++ storm/schema/__init__.py 2019-06-05 11:42:41 +0000
221@@ -18,4 +18,6 @@
222 # You should have received a copy of the GNU Lesser General Public License
223 # along with this program. If not, see <http://www.gnu.org/licenses/>.
224 #
225+from __future__ import print_function
226+
227 from storm.schema.schema import Schema
228
229=== modified file 'storm/schema/patch.py'
230--- storm/schema/patch.py 2014-12-12 11:14:47 +0000
231+++ storm/schema/patch.py 2019-06-05 11:42:41 +0000
232@@ -34,6 +34,8 @@
233 'patch' table in the given L{Store}, and it won't be applied again.
234 """
235
236+from __future__ import print_function
237+
238 import sys
239 import os
240 import re
241@@ -207,7 +209,7 @@
242 >>> import mypackage
243 >>> patch_set = PackagePackage(mypackage, sub_level="foo")
244 >>> patch_module = patch_set.get_patch_module(1)
245- >>> print patch_module.__name__
246+ >>> print(patch_module.__name__)
247 'mypackage.patch_1.foo'
248
249 Different sub-levels can be used to apply different patches to different
250@@ -222,7 +224,7 @@
251 >>> import mypackage
252 >>> patch_set = PackagePackage(mypackage)
253 >>> patch_module = patch_set.get_patch_module(1)
254- >>> print patch_module.__name__
255+ >>> print(patch_module.__name__)
256 'mypackage.patch_1'
257
258 This simpler structure can be used if you have just one store to patch
259
260=== modified file 'storm/schema/schema.py'
261--- storm/schema/schema.py 2019-05-30 13:39:54 +0000
262+++ storm/schema/schema.py 2019-06-05 11:42:41 +0000
263@@ -43,6 +43,8 @@
264 upgrade the schema over time.
265 """
266
267+from __future__ import print_function
268+
269 import types
270
271 from storm.locals import StormError
272@@ -96,7 +98,7 @@
273 try:
274 store.execute(statement)
275 except Exception:
276- print "Error running %s" % statement
277+ print("Error running %s" % statement)
278 raise
279 if self._autocommit:
280 store.commit()
281
282=== modified file 'storm/schema/sharding.py'
283--- storm/schema/sharding.py 2019-05-30 13:39:54 +0000
284+++ storm/schema/sharding.py 2019-06-05 11:42:41 +0000
285@@ -41,6 +41,8 @@
286 be at the same patch level. See L{storm.schema.patch.PatchSet}.
287 """
288
289+from __future__ import print_function
290+
291 from storm.schema.schema import SchemaMissingError, UnappliedPatchesError
292
293
294
295=== modified file 'storm/sqlobject.py'
296--- storm/sqlobject.py 2011-10-17 15:59:25 +0000
297+++ storm/sqlobject.py 2019-06-05 11:42:41 +0000
298@@ -23,6 +23,8 @@
299 L{SQLObjectBase} is the central point of compatibility.
300 """
301
302+from __future__ import print_function
303+
304 import re
305 import warnings
306
307
308=== modified file 'storm/store.py'
309--- storm/store.py 2019-06-05 10:41:32 +0000
310+++ storm/store.py 2019-06-05 11:42:41 +0000
311@@ -24,6 +24,8 @@
312 This module contains the highest-level ORM interface in Storm.
313 """
314
315+from __future__ import print_function
316+
317 from copy import copy
318 from weakref import WeakValueDictionary
319 from operator import itemgetter
320@@ -237,7 +239,7 @@
321 required. An example follows::
322
323 join = LeftJoin(Person, Person.id == Company.person_id)
324- print list(store.using(Company, join).find((Company, Person)))
325+ print(list(store.using(Company, join).find((Company, Person))))
326
327 The previous code snippet will produce an SQL statement
328 somewhat similar to this, depending on your backend::
329
330=== modified file 'storm/testing.py'
331--- storm/testing.py 2012-03-21 14:43:26 +0000
332+++ storm/testing.py 2019-06-05 11:42:41 +0000
333@@ -1,3 +1,5 @@
334+from __future__ import print_function
335+
336 from fixtures import Fixture
337
338 from storm.tracer import BaseStatementTracer, install_tracer, remove_tracer
339@@ -10,7 +12,7 @@
340
341 with CaptureTracer() as tracer:
342 # Run queries
343- print tracer.queries # Print the queries that have been run
344+ print(tracer.queries) # Print the queries that have been run
345
346 @note: This class requires the fixtures package to be available.
347 """
348
349=== modified file 'storm/tracer.py'
350--- storm/tracer.py 2012-06-28 13:08:48 +0000
351+++ storm/tracer.py 2019-06-05 11:42:41 +0000
352@@ -1,3 +1,5 @@
353+from __future__ import print_function
354+
355 from datetime import datetime
356 import re
357 import sys
358
359=== modified file 'storm/twisted/testing.py'
360--- storm/twisted/testing.py 2011-11-30 14:16:50 +0000
361+++ storm/twisted/testing.py 2019-06-05 11:42:41 +0000
362@@ -1,3 +1,5 @@
363+from __future__ import print_function
364+
365 import transaction
366
367 from twisted.python.failure import Failure
368
369=== modified file 'storm/twisted/transact.py'
370--- storm/twisted/transact.py 2019-05-30 13:39:54 +0000
371+++ storm/twisted/transact.py 2019-06-05 11:42:41 +0000
372@@ -1,3 +1,5 @@
373+from __future__ import print_function
374+
375 import time
376 import random
377 import transaction
378
379=== modified file 'storm/tz.py'
380--- storm/tz.py 2007-08-07 18:36:04 +0000
381+++ storm/tz.py 2019-06-05 11:42:41 +0000
382@@ -4,6 +4,8 @@
383 This module offers extensions to the standard python 2.3+
384 datetime module.
385 """
386+from __future__ import print_function
387+
388 __author__ = "Gustavo Niemeyer <gustavo@niemeyer.net>"
389 __license__ = "PSF License"
390
391
392=== modified file 'storm/uri.py'
393--- storm/uri.py 2008-01-30 13:03:27 +0000
394+++ storm/uri.py 2019-06-05 11:42:41 +0000
395@@ -18,6 +18,8 @@
396 # You should have received a copy of the GNU Lesser General Public License
397 # along with this program. If not, see <http://www.gnu.org/licenses/>.
398 #
399+from __future__ import print_function
400+
401 from urllib import quote
402
403 from storm.exceptions import URIError
404
405=== modified file 'storm/variables.py'
406--- storm/variables.py 2019-06-05 10:41:32 +0000
407+++ storm/variables.py 2019-06-05 11:42:41 +0000
408@@ -18,6 +18,8 @@
409 # You should have received a copy of the GNU Lesser General Public License
410 # along with this program. If not, see <http://www.gnu.org/licenses/>.
411 #
412+from __future__ import print_function
413+
414 from datetime import datetime, date, time, timedelta
415 from decimal import Decimal
416 from functools import partial
417
418=== modified file 'storm/wsgi.py'
419--- storm/wsgi.py 2012-06-04 14:14:50 +0000
420+++ storm/wsgi.py 2019-06-05 11:42:41 +0000
421@@ -21,6 +21,8 @@
422
423 """Glue to wire a storm timeline tracer up to a WSGI app."""
424
425+from __future__ import print_function
426+
427 import threading
428 import weakref
429
430
431=== modified file 'storm/xid.py'
432--- storm/xid.py 2012-03-01 13:28:26 +0000
433+++ storm/xid.py 2019-06-05 11:42:41 +0000
434@@ -19,6 +19,8 @@
435 # along with this program. If not, see <http://www.gnu.org/licenses/>.
436 #
437
438+from __future__ import print_function
439+
440
441 class Xid(object):
442 """
443
444=== modified file 'storm/zope/__init__.py'
445--- storm/zope/__init__.py 2008-07-30 06:07:40 +0000
446+++ storm/zope/__init__.py 2019-06-05 11:42:41 +0000
447@@ -18,6 +18,8 @@
448 # You should have received a copy of the GNU Lesser General Public License
449 # along with this program. If not, see <http://www.gnu.org/licenses/>.
450 #
451+from __future__ import print_function
452+
453 from zope.interface import classImplements
454
455 from storm.info import ObjectInfo
456
457=== modified file 'storm/zope/adapters.py'
458--- storm/zope/adapters.py 2009-03-05 11:17:47 +0000
459+++ storm/zope/adapters.py 2019-06-05 11:42:41 +0000
460@@ -19,6 +19,8 @@
461 # along with this program. If not, see <http://www.gnu.org/licenses/>.
462 #
463
464+from __future__ import print_function
465+
466 from zope.component import adapter
467 from zope.interface import implementer
468
469
470=== modified file 'storm/zope/interfaces.py'
471--- storm/zope/interfaces.py 2011-04-13 03:20:36 +0000
472+++ storm/zope/interfaces.py 2019-06-05 11:42:41 +0000
473@@ -18,6 +18,8 @@
474 # You should have received a copy of the GNU Lesser General Public License
475 # along with this program. If not, see <http://www.gnu.org/licenses/>.
476 #
477+from __future__ import print_function
478+
479 from zope.interface import Interface
480
481 from storm.expr import Undef
482
483=== modified file 'storm/zope/metaconfigure.py'
484--- storm/zope/metaconfigure.py 2007-08-05 21:59:54 +0000
485+++ storm/zope/metaconfigure.py 2019-06-05 11:42:41 +0000
486@@ -18,6 +18,8 @@
487 # You should have received a copy of the GNU Lesser General Public License
488 # along with this program. If not, see <http://www.gnu.org/licenses/>.
489 #
490+from __future__ import print_function
491+
492 from zope import component
493
494 from storm.zope.interfaces import IZStorm
495
496=== modified file 'storm/zope/metadirectives.py'
497--- storm/zope/metadirectives.py 2007-08-05 21:59:54 +0000
498+++ storm/zope/metadirectives.py 2019-06-05 11:42:41 +0000
499@@ -18,6 +18,8 @@
500 # You should have received a copy of the GNU Lesser General Public License
501 # along with this program. If not, see <http://www.gnu.org/licenses/>.
502 #
503+from __future__ import print_function
504+
505 from zope.interface import Interface
506 from zope.schema import TextLine
507
508
509=== modified file 'storm/zope/schema.py'
510--- storm/zope/schema.py 2010-08-17 14:00:59 +0000
511+++ storm/zope/schema.py 2019-06-05 11:42:41 +0000
512@@ -19,6 +19,8 @@
513 # along with this program. If not, see <http://www.gnu.org/licenses/>.
514 #
515 """ZStorm-aware schema manager."""
516+from __future__ import print_function
517+
518 import transaction
519
520 from storm.schema import Schema
521
522=== modified file 'storm/zope/testing.py'
523--- storm/zope/testing.py 2014-12-18 11:37:22 +0000
524+++ storm/zope/testing.py 2019-06-05 11:42:41 +0000
525@@ -18,6 +18,8 @@
526 # You should have received a copy of the GNU Lesser General Public License
527 # along with this program. If not, see <http://www.gnu.org/licenses/>.
528 #
529+from __future__ import print_function
530+
531 import os
532 import shutil
533
534
535=== modified file 'storm/zope/zstorm.py'
536--- storm/zope/zstorm.py 2012-03-28 10:57:43 +0000
537+++ storm/zope/zstorm.py 2019-06-05 11:42:41 +0000
538@@ -24,6 +24,8 @@
539 # You should have received a copy of the GNU Lesser General Public License
540 # along with this program. If not, see <http://www.gnu.org/licenses/>.
541 #
542+from __future__ import print_function
543+
544 import threading
545 import weakref
546
547
548=== modified file 'tests/__init__.py'
549--- tests/__init__.py 2011-12-07 10:56:24 +0000
550+++ tests/__init__.py 2019-06-05 11:42:41 +0000
551@@ -19,6 +19,8 @@
552 # along with this program. If not, see <http://www.gnu.org/licenses/>.
553 #
554
555+from __future__ import print_function
556+
557 __all__ = [
558 'find_tests',
559 'has_fixtures',
560@@ -111,6 +113,7 @@
561 os.path.basename(relpath),
562 module_relative=True,
563 package=parent_module,
564+ globs={"print_function": print_function},
565 optionflags=doctest.ELLIPSIS))
566
567 return suite
568
569=== modified file 'tests/base.py'
570--- tests/base.py 2007-07-18 21:41:04 +0000
571+++ tests/base.py 2019-06-05 11:42:41 +0000
572@@ -18,6 +18,8 @@
573 # You should have received a copy of the GNU Lesser General Public License
574 # along with this program. If not, see <http://www.gnu.org/licenses/>.
575 #
576+from __future__ import print_function
577+
578 import weakref
579 import gc
580
581
582=== modified file 'tests/cache.py'
583--- tests/cache.py 2011-07-14 11:15:30 +0000
584+++ tests/cache.py 2019-06-05 11:42:41 +0000
585@@ -1,3 +1,5 @@
586+from __future__ import print_function
587+
588 from unittest import defaultTestLoader
589
590 from storm.properties import Int
591
592=== modified file 'tests/database.py'
593--- tests/database.py 2013-02-15 17:00:18 +0000
594+++ tests/database.py 2019-06-05 11:42:41 +0000
595@@ -18,6 +18,8 @@
596 # You should have received a copy of the GNU Lesser General Public License
597 # along with this program. If not, see <http://www.gnu.org/licenses/>.
598 #
599+from __future__ import print_function
600+
601 import sys
602 import new
603 import gc
604
605=== modified file 'tests/databases/base.py'
606--- tests/databases/base.py 2019-05-30 13:39:54 +0000
607+++ tests/databases/base.py 2019-06-05 11:42:41 +0000
608@@ -20,6 +20,8 @@
609 # You should have received a copy of the GNU Lesser General Public License
610 # along with this program. If not, see <http://www.gnu.org/licenses/>.
611 #
612+from __future__ import print_function
613+
614 from datetime import datetime, date, time, timedelta
615 import cPickle as pickle
616 import shutil
617
618=== modified file 'tests/databases/postgres.py'
619--- tests/databases/postgres.py 2019-05-31 19:00:58 +0000
620+++ tests/databases/postgres.py 2019-06-05 11:42:41 +0000
621@@ -18,6 +18,8 @@
622 # You should have received a copy of the GNU Lesser General Public License
623 # along with this program. If not, see <http://www.gnu.org/licenses/>.
624 #
625+from __future__ import print_function
626+
627 from datetime import date, time, timedelta
628 import os
629 import json
630
631=== modified file 'tests/databases/proxy.py'
632--- tests/databases/proxy.py 2007-10-24 06:27:06 +0000
633+++ tests/databases/proxy.py 2019-06-05 11:42:41 +0000
634@@ -20,6 +20,8 @@
635 # along with this program. If not, see <http://www.gnu.org/licenses/>.
636 #
637
638+from __future__ import print_function
639+
640 import os
641 import select
642 import socket
643
644=== modified file 'tests/databases/sqlite.py'
645--- tests/databases/sqlite.py 2019-05-30 13:39:54 +0000
646+++ tests/databases/sqlite.py 2019-06-05 11:42:41 +0000
647@@ -18,6 +18,8 @@
648 # You should have received a copy of the GNU Lesser General Public License
649 # along with this program. If not, see <http://www.gnu.org/licenses/>.
650 #
651+from __future__ import print_function
652+
653 from datetime import timedelta
654 import time
655 import os
656
657=== modified file 'tests/event.py'
658--- tests/event.py 2008-06-18 15:27:03 +0000
659+++ tests/event.py 2019-06-05 11:42:41 +0000
660@@ -18,6 +18,8 @@
661 # You should have received a copy of the GNU Lesser General Public License
662 # along with this program. If not, see <http://www.gnu.org/licenses/>.
663 #
664+from __future__ import print_function
665+
666 from storm.event import EventSystem
667
668 from tests.helper import TestHelper
669
670=== modified file 'tests/expr.py'
671--- tests/expr.py 2019-06-05 10:41:32 +0000
672+++ tests/expr.py 2019-06-05 11:42:41 +0000
673@@ -18,6 +18,8 @@
674 # You should have received a copy of the GNU Lesser General Public License
675 # along with this program. If not, see <http://www.gnu.org/licenses/>.
676 #
677+from __future__ import print_function
678+
679 from decimal import Decimal
680 import unittest
681
682
683=== modified file 'tests/helper.py'
684--- tests/helper.py 2019-06-03 08:45:24 +0000
685+++ tests/helper.py 2019-06-05 11:42:41 +0000
686@@ -18,6 +18,8 @@
687 # You should have received a copy of the GNU Lesser General Public License
688 # along with this program. If not, see <http://www.gnu.org/licenses/>.
689 #
690+from __future__ import print_function
691+
692 from cStringIO import StringIO
693 import tempfile
694 import logging
695
696=== modified file 'tests/info.py'
697--- tests/info.py 2011-12-07 11:57:07 +0000
698+++ tests/info.py 2019-06-05 11:42:41 +0000
699@@ -18,6 +18,8 @@
700 # You should have received a copy of the GNU Lesser General Public License
701 # along with this program. If not, see <http://www.gnu.org/licenses/>.
702 #
703+from __future__ import print_function
704+
705 from weakref import ref
706 import gc
707
708
709=== modified file 'tests/mocker.py'
710--- tests/mocker.py 2019-06-03 08:45:24 +0000
711+++ tests/mocker.py 2019-06-05 11:42:41 +0000
712@@ -3,6 +3,8 @@
713
714 Graceful platform for test doubles in Python (mocks, stubs, fakes, and dummies).
715 """
716+from __future__ import print_function
717+
718 import __builtin__
719 import tempfile
720 import unittest
721
722=== modified file 'tests/properties.py'
723--- tests/properties.py 2019-06-03 08:45:24 +0000
724+++ tests/properties.py 2019-06-05 11:42:41 +0000
725@@ -18,6 +18,8 @@
726 # You should have received a copy of the GNU Lesser General Public License
727 # along with this program. If not, see <http://www.gnu.org/licenses/>.
728 #
729+from __future__ import print_function
730+
731 from datetime import datetime, date, time, timedelta
732 from decimal import Decimal as decimal
733 import gc
734
735=== modified file 'tests/schema/patch.py'
736--- tests/schema/patch.py 2019-05-30 13:39:54 +0000
737+++ tests/schema/patch.py 2019-06-05 11:42:41 +0000
738@@ -18,6 +18,8 @@
739 # You should have received a copy of the GNU Lesser General Public License
740 # along with this program. If not, see <http://www.gnu.org/licenses/>.
741 #
742+from __future__ import print_function
743+
744 import traceback
745 import sys
746 import os
747
748=== modified file 'tests/schema/schema.py'
749--- tests/schema/schema.py 2015-01-26 09:57:25 +0000
750+++ tests/schema/schema.py 2019-06-05 11:42:41 +0000
751@@ -18,6 +18,8 @@
752 # You should have received a copy of the GNU Lesser General Public License
753 # along with this program. If not, see <http://www.gnu.org/licenses/>.
754 #
755+from __future__ import print_function
756+
757 import os
758 import sys
759
760
761=== modified file 'tests/schema/sharding.py'
762--- tests/schema/sharding.py 2014-12-18 11:37:22 +0000
763+++ tests/schema/sharding.py 2019-06-05 11:42:41 +0000
764@@ -18,6 +18,8 @@
765 # You should have received a copy of the GNU Lesser General Public License
766 # along with this program. If not, see <http://www.gnu.org/licenses/>.
767 #
768+from __future__ import print_function
769+
770 from tests.mocker import MockerTestCase
771
772 from storm.schema.schema import SchemaMissingError, UnappliedPatchesError
773
774=== modified file 'tests/sqlobject.py'
775--- tests/sqlobject.py 2016-03-01 11:44:05 +0000
776+++ tests/sqlobject.py 2019-06-05 11:42:41 +0000
777@@ -18,6 +18,8 @@
778 # You should have received a copy of the GNU Lesser General Public License
779 # along with this program. If not, see <http://www.gnu.org/licenses/>.
780 #
781+from __future__ import print_function
782+
783 import datetime
784 import operator
785
786
787=== modified file 'tests/store/base.py'
788--- tests/store/base.py 2019-06-05 10:41:32 +0000
789+++ tests/store/base.py 2019-06-05 11:42:41 +0000
790@@ -20,6 +20,8 @@
791 # along with this program. If not, see <http://www.gnu.org/licenses/>.
792 #
793
794+from __future__ import print_function
795+
796 import cPickle as pickle
797 from cStringIO import StringIO
798 import decimal
799
800=== modified file 'tests/store/postgres.py'
801--- tests/store/postgres.py 2012-03-08 13:46:23 +0000
802+++ tests/store/postgres.py 2019-06-05 11:42:41 +0000
803@@ -18,6 +18,8 @@
804 # You should have received a copy of the GNU Lesser General Public License
805 # along with this program. If not, see <http://www.gnu.org/licenses/>.
806 #
807+from __future__ import print_function
808+
809 import os
810 import gc
811
812
813=== modified file 'tests/store/sqlite.py'
814--- tests/store/sqlite.py 2011-02-14 12:17:54 +0000
815+++ tests/store/sqlite.py 2019-06-05 11:42:41 +0000
816@@ -18,6 +18,8 @@
817 # You should have received a copy of the GNU Lesser General Public License
818 # along with this program. If not, see <http://www.gnu.org/licenses/>.
819 #
820+from __future__ import print_function
821+
822 from storm.databases.sqlite import SQLite
823 from storm.uri import URI
824
825
826=== modified file 'tests/tracer.py'
827--- tests/tracer.py 2019-05-30 13:39:54 +0000
828+++ tests/tracer.py 2019-06-05 11:42:41 +0000
829@@ -1,3 +1,5 @@
830+from __future__ import print_function
831+
832 import datetime
833 import os
834 import sys
835
836=== modified file 'tests/tutorial.txt'
837--- tests/tutorial.txt 2016-03-10 12:04:01 +0000
838+++ tests/tutorial.txt 2019-06-05 11:42:41 +0000
839@@ -73,7 +73,7 @@
840 >>> joe = Person()
841 >>> joe.name = u"Joe Johnes"
842
843->>> print "%r, %r" % (joe.id, joe.name)
844+>>> print("%r, %r" % (joe.id, joe.name))
845 None, u'Joe Johnes'
846
847 }}}
848@@ -85,7 +85,7 @@
849 >>> store.add(joe)
850 <...Person object at 0x...>
851
852->>> print "%r, %r" % (joe.id, joe.name)
853+>>> print("%r, %r" % (joe.id, joe.name))
854 None, u'Joe Johnes'
855
856 }}}
857@@ -116,7 +116,7 @@
858 {{{#!python
859 >>> person = store.find(Person, Person.name == u"Joe Johnes").one()
860
861->>> print "%r, %r" % (person.id, person.name)
862+>>> print("%r, %r" % (person.id, person.name))
863 1, u'Joe Johnes'
864
865 >>>
866@@ -168,11 +168,11 @@
867 >>> store.add(mary)
868 <...Person object at 0x...>
869
870->>> print "%r, %r" % (mary.id, mary.name)
871+>>> print("%r, %r" % (mary.id, mary.name))
872 None, u'Mary Margaret'
873
874 >>> store.flush()
875->>> print "%r, %r" % (mary.id, mary.name)
876+>>> print("%r, %r" % (mary.id, mary.name))
877 2, u'Mary Margaret'
878
879 }}}
880@@ -240,7 +240,7 @@
881 Actually, something happened.. with Joe. He's back!
882
883 {{{#!python
884->>> print "%r, %r" % (joe.id, joe.name)
885+>>> print("%r, %r" % (joe.id, joe.name))
886 1, u'Joe Johnes'
887
888 }}}
889@@ -279,7 +279,7 @@
890 {{{
891 >>> circus = Company(u"Circus Inc.")
892
893->>> print "%r, %r" % (circus.id, circus.name)
894+>>> print("%r, %r" % (circus.id, circus.name))
895 None, u'Circus Inc.'
896
897 }}}
898@@ -327,7 +327,7 @@
899 {{{#!python
900 >>> ben = store.add(Employee(u"Ben Bill"))
901
902->>> print "%r, %r, %r" % (ben.id, ben.name, ben.company_id)
903+>>> print("%r, %r, %r" % (ben.id, ben.name, ben.company_id))
904 None, u'Ben Bill', None
905
906 }}}
907@@ -338,7 +338,7 @@
908 {{{#!python
909 >>> ben.company = circus
910
911->>> print "%r, %r" % (ben.company_id, ben.company.name)
912+>>> print("%r, %r" % (ben.company_id, ben.company.name))
913 None, u'Circus Inc.'
914
915 }}}
916@@ -354,7 +354,7 @@
917 {{{#!python
918 >>> store.flush()
919
920->>> print "%r, %r" % (ben.company_id, ben.company.name)
921+>>> print("%r, %r" % (ben.company_id, ben.company.name))
922 1, u'Circus Inc.'
923
924 }}}
925@@ -419,8 +419,8 @@
926 1
927
928 >>> for employee in sweets.employees:
929-... print "%r, %r" % (employee.id, employee.name)
930-... print employee is ben
931+... print("%r, %r" % (employee.id, employee.name))
932+... print(employee is ben)
933 ...
934 1, u'Ben Bill'
935 True
936@@ -742,11 +742,11 @@
937 {{{#!python
938 >>> class PersonWithHook(Person):
939 ... def __init__(self, name):
940-... print "Creating %s" % name
941+... print("Creating %s" % name)
942 ... self.name = name
943 ...
944 ... def __storm_loaded__(self):
945-... print "Loaded %s" % self.name
946+... print("Loaded %s" % self.name)
947
948
949 >>> earl = store.add(PersonWithHook(u"Earl Easton"))
950@@ -803,11 +803,11 @@
951
952 >>> ruy = store.add(Person())
953 >>> ruy.name = u"Ruy"
954->>> print ruy.id
955+>>> print(ruy.id)
956 None
957
958 >>> ruy.id = AutoReload
959->>> print ruy.id
960+>>> print(ruy.id)
961 4
962
963 }}}
964@@ -865,7 +865,7 @@
965 ... Employee.id > AnotherEmployee.id)
966
967 >>> for employee1, employee2 in result:
968-... print (employee1.name, employee2.name)
969+... print((employee1.name, employee2.name))
970 (u'Mike Mayer', u'Ben Bill')
971
972 }}}
973
974=== modified file 'tests/twisted/__init__.py'
975--- tests/twisted/__init__.py 2011-12-07 10:56:24 +0000
976+++ tests/twisted/__init__.py 2019-06-05 11:42:41 +0000
977@@ -1,3 +1,5 @@
978+from __future__ import print_function
979+
980 __all__ = [
981 'has_twisted',
982 ]
983
984=== modified file 'tests/twisted/transact.py'
985--- tests/twisted/transact.py 2011-12-07 13:23:25 +0000
986+++ tests/twisted/transact.py 2019-06-05 11:42:41 +0000
987@@ -1,3 +1,5 @@
988+from __future__ import print_function
989+
990 from tests import has_psycopg
991 from tests.helper import TestHelper
992 from tests.zope import has_transaction, has_zope_component
993
994=== modified file 'tests/uri.py'
995--- tests/uri.py 2008-01-30 13:03:27 +0000
996+++ tests/uri.py 2019-06-05 11:42:41 +0000
997@@ -18,6 +18,8 @@
998 # You should have received a copy of the GNU Lesser General Public License
999 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1000 #
1001+from __future__ import print_function
1002+
1003 from storm.uri import URI, URIError
1004
1005 from tests.helper import TestHelper
1006
1007=== modified file 'tests/variables.py'
1008--- tests/variables.py 2019-06-05 10:41:32 +0000
1009+++ tests/variables.py 2019-06-05 11:42:41 +0000
1010@@ -18,6 +18,8 @@
1011 # You should have received a copy of the GNU Lesser General Public License
1012 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1013 #
1014+from __future__ import print_function
1015+
1016 from datetime import datetime, date, time, timedelta
1017 from decimal import Decimal
1018 import cPickle as pickle
1019
1020=== modified file 'tests/wsgi.py'
1021--- tests/wsgi.py 2012-06-04 14:14:50 +0000
1022+++ tests/wsgi.py 2019-06-05 11:42:41 +0000
1023@@ -1,3 +1,5 @@
1024+from __future__ import print_function
1025+
1026 import Queue
1027 from unittest import TestCase
1028 import threading
1029
1030=== modified file 'tests/zope/__init__.py'
1031--- tests/zope/__init__.py 2011-09-13 10:43:40 +0000
1032+++ tests/zope/__init__.py 2019-06-05 11:42:41 +0000
1033@@ -18,6 +18,8 @@
1034 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1035 #
1036
1037+from __future__ import print_function
1038+
1039 __all__ = [
1040 'has_transaction',
1041 'has_zope_component',
1042
1043=== modified file 'tests/zope/adapters.py'
1044--- tests/zope/adapters.py 2009-03-05 21:53:12 +0000
1045+++ tests/zope/adapters.py 2019-06-05 11:42:41 +0000
1046@@ -18,6 +18,8 @@
1047 # You should have received a copy of the GNU Lesser General Public License
1048 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1049 #
1050+from __future__ import print_function
1051+
1052 from tests.helper import TestHelper
1053 from tests.zope import has_zope_component
1054
1055
1056=== modified file 'tests/zope/testing.py'
1057--- tests/zope/testing.py 2015-05-11 08:47:32 +0000
1058+++ tests/zope/testing.py 2019-06-05 11:42:41 +0000
1059@@ -18,6 +18,8 @@
1060 # You should have received a copy of the GNU Lesser General Public License
1061 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1062 #
1063+from __future__ import print_function
1064+
1065 import os
1066 import sys
1067
1068
1069=== modified file 'tests/zope/zstorm.py'
1070--- tests/zope/zstorm.py 2019-05-31 15:28:04 +0000
1071+++ tests/zope/zstorm.py 2019-06-05 11:42:41 +0000
1072@@ -18,6 +18,8 @@
1073 # You should have received a copy of the GNU Lesser General Public License
1074 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1075 #
1076+from __future__ import print_function
1077+
1078 import threading
1079 import weakref
1080 import gc

Subscribers

People subscribed via source and target branches

to status/vote changes: