diff -r 13be42829771 Lib/getpass.py --- a/Lib/getpass.py Wed Oct 28 03:15:38 2015 -0400 +++ b/Lib/getpass.py Thu Oct 29 12:36:53 2015 +1100 @@ -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 -r 13be42829771 Lib/pickletools.py --- a/Lib/pickletools.py Wed Oct 28 03:15:38 2015 -0400 +++ b/Lib/pickletools.py Thu Oct 29 12:36:53 2015 +1100 @@ -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 -r 13be42829771 Lib/smtplib.py --- a/Lib/smtplib.py Wed Oct 28 03:15:38 2015 -0400 +++ b/Lib/smtplib.py Thu Oct 29 12:36:53 2015 +1100 @@ -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 -r 13be42829771 PC/testpy.py --- a/PC/testpy.py Wed Oct 28 03:15:38 2015 -0400 +++ b/PC/testpy.py Thu Oct 29 12:36:53 2015 +1100 @@ -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):