1758 # search the path for the module |
1758 # search the path for the module |
1759 path = [] if path is None else path[:] |
1759 path = [] if path is None else path[:] |
1760 f = None |
1760 f = None |
1761 if inpackage: |
1761 if inpackage: |
1762 try: |
1762 try: |
1763 f, file, (suff, mode, moduleType) = find_module( |
1763 f, file, (_suff, _mode, moduleType) = find_module( |
1764 module, path, _extensions |
1764 module, path, _extensions |
1765 ) |
1765 ) |
1766 except ImportError: |
1766 except ImportError: |
1767 f = None |
1767 f = None |
1768 if f is None: |
1768 if f is None: |
1769 fullpath = path[:] + sys.path[:] |
1769 fullpath = path[:] + sys.path[:] |
1770 f, file, (suff, mode, moduleType) = find_module( |
1770 f, file, (_suff, _mode, moduleType) = find_module( |
1771 module, fullpath, _extensions |
1771 module, fullpath, _extensions |
1772 ) |
1772 ) |
1773 if f: |
1773 if f: |
1774 f.close() |
1774 f.close() |
1775 |
1775 |