comparison contrib/import-checker.py @ 26062:7154a4a08b96

import-checker: ensure multiprocessing is treated as from stdlib On my linux machines multiprocessing appears to defeat the logic in import-checker to detect stdlib modules. Since we now only use versions of Python which ship with multiprocessing, let's just whitelist the module.
author Augie Fackler <augie@google.com>
date Mon, 24 Aug 2015 10:09:00 -0400
parents 9086d0c1def3
children bb6936bec727
comparison
equal deleted inserted replaced
26061:be8a4e0800d8 26062:7154a4a08b96
162 # These modules only exist on windows, but we should always 162 # These modules only exist on windows, but we should always
163 # consider them stdlib. 163 # consider them stdlib.
164 for m in ['msvcrt', '_winreg']: 164 for m in ['msvcrt', '_winreg']:
165 yield m 165 yield m
166 # These get missed too 166 # These get missed too
167 for m in 'ctypes', 'email': 167 for m in 'ctypes', 'email', 'multiprocessing':
168 yield m 168 yield m
169 yield 'builtins' # python3 only 169 yield 'builtins' # python3 only
170 for m in 'fcntl', 'grp', 'pwd', 'termios': # Unix only 170 for m in 'fcntl', 'grp', 'pwd', 'termios': # Unix only
171 yield m 171 yield m
172 stdlib_prefixes = set([sys.prefix, sys.exec_prefix]) 172 stdlib_prefixes = set([sys.prefix, sys.exec_prefix])