[Python-checkins] cpython (merge 3.5 -> default): merge 3.5 (#25502)
benjamin.peterson
python-checkins at python.org
Thu Oct 29 02:17:57 EDT 2015
https://hg.python.org/cpython/rev/695c50c8cc92
changeset: 98881:695c50c8cc92
parent: 98879:8d3932671e48
parent: 98880:dec0a26d0b4d
user: Benjamin Peterson <benjamin at python.org>
date: Wed Oct 28 23:15:22 2015 -0700
summary:
merge 3.5 (#25502)
files:
Lib/getpass.py | 2 +-
Lib/pickletools.py | 2 +-
Lib/smtplib.py | 2 --
PC/testpy.py | 2 --
Parser/asdl_c.py | 1 -
5 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/Lib/getpass.py b/Lib/getpass.py
--- a/Lib/getpass.py
+++ b/Lib/getpass.py
@@ -99,7 +99,7 @@
"""Prompt for password with echo off, using Windows getch()."""
if sys.stdin is not sys.__stdin__:
return fallback_getpass(prompt, stream)
- import msvcrt
+
for c in prompt:
msvcrt.putwch(c)
pw = ""
diff --git a/Lib/pickletools.py b/Lib/pickletools.py
--- a/Lib/pickletools.py
+++ b/Lib/pickletools.py
@@ -2794,7 +2794,7 @@
return doctest.testmod()
if __name__ == "__main__":
- import sys, argparse
+ import argparse
parser = argparse.ArgumentParser(
description='disassemble one or more pickle files')
parser.add_argument(
diff --git a/Lib/smtplib.py b/Lib/smtplib.py
--- a/Lib/smtplib.py
+++ b/Lib/smtplib.py
@@ -1080,8 +1080,6 @@
# Test the sendmail method, which tests most of the others.
# Note: This always sends to localhost.
if __name__ == '__main__':
- import sys
-
def prompt(prompt):
sys.stdout.write(prompt + ": ")
sys.stdout.flush()
diff --git a/PC/testpy.py b/PC/testpy.py
--- a/PC/testpy.py
+++ b/PC/testpy.py
@@ -18,8 +18,6 @@
a PC, you should add the dos_8x3 directory to your PYTHONPATH.""")
sys.exit(1)
-import os
-
for dir in sys.path:
file = os.path.join(dir, "os.py")
if os.path.isfile(file):
diff --git a/Parser/asdl_c.py b/Parser/asdl_c.py
--- a/Parser/asdl_c.py
+++ b/Parser/asdl_c.py
@@ -1289,7 +1289,6 @@
f.close()
if __name__ == "__main__":
- import sys
import getopt
INC_DIR = ''
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list