import-checker: allow *.pyd based stdlib modules
authorMatt Harbison <matt_harbison@yahoo.com>
Wed, 08 Apr 2015 22:23:51 -0400
changeset 24668 81873bb2a01d
parent 24667 19c5b0913960
child 24669 fbdbff1b486a
import-checker: allow *.pyd based stdlib modules These are Windows dlls, and eliminate the following import check diffs that are not on Unix: mercurial/changegroup.py mixed imports stdlib: os, struct, tempfile, zlib relative: bz2 mercurial/encoding.py mixed imports stdlib: locale, os relative: unicodedata
contrib/import-checker.py
--- a/contrib/import-checker.py	Tue Apr 07 22:35:44 2015 -0700
+++ b/contrib/import-checker.py	Wed Apr 08 22:23:51 2015 -0400
@@ -90,7 +90,8 @@
             for name in files:
                 if name == '__init__.py':
                     continue
-                if not (name.endswith('.py') or name.endswith('.so')):
+                if not (name.endswith('.py') or name.endswith('.so')
+                        or name.endswith('.pyd')):
                     continue
                 full_path = os.path.join(top, name)
                 if 'site-packages' in full_path: