Skip to content

Commit 44e1e1e

Browse files
Fix tasks,py release-notes with Python 3
1 parent cc496f4 commit 44e1e1e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tasks.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@
2424

2525
try:
2626
from StringIO import StringIO
27+
PY3 = False
2728
except ImportError: # py3
2829
from io import StringIO
30+
PY3 = True
2931
try:
3032
import urllib2
3133
except ImportError: # py3
@@ -330,7 +332,10 @@ def _get_issues():
330332
import getpass
331333
from github3 import login
332334
milestone = re.split('[ab-]', VERSION)[0]
333-
username = raw_input('Enter GitHub username for downloading issues: ')
335+
if not PY3:
336+
username = raw_input('Enter GitHub username for downloading issues: ')
337+
else:
338+
username = input('Enter GitHub username for downloading issues: ')
334339
password = getpass.getpass(
335340
'Github password for {user}: '.format(user=username))
336341
gh = login(username, password=password)

0 commit comments

Comments
 (0)