micropython

Changeset

579:9df30d738ec1
2012-07-07 Paul Boddie raw files shortlog changelog graph Filter out __init__.py files when looking for submodule files.
micropython/__init__.py (file)
     1.1 --- a/micropython/__init__.py	Fri Jul 06 01:52:10 2012 +0200
     1.2 +++ b/micropython/__init__.py	Sat Jul 07 20:35:17 2012 +0200
     1.3 @@ -1088,7 +1088,7 @@
     1.4  
     1.5          for filename in os.listdir(pathname):
     1.6              submodule, ext = os.path.splitext(filename)
     1.7 -            if ext not in ("", ".py"):
     1.8 +            if submodule == "__init__" or ext not in ("", ".py"):
     1.9                  continue
    1.10              module.set_module(submodule, self.add_module(module.name + "." + submodule))
    1.11