diff roundup/anypy/my_input.py @ 5401:4cf48ff01e04

Python 3 preparation: replace raw_input uses. The existing my_input in roundup/admin.py is moved to a new roundup/anypy/my_input.py, which is then used in more places. Manual patch.
author Joseph Myers <jsm@polyomino.org.uk>
date Tue, 24 Jul 2018 23:47:10 +0000
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/roundup/anypy/my_input.py	Tue Jul 24 23:47:10 2018 +0000
@@ -0,0 +1,6 @@
+try:
+    # Python 2.
+    my_input = raw_input
+except NameError:
+    # Python 3+.
+    my_input = input

Roundup Issue Tracker: http://roundup-tracker.org/