code: def build_tree(self):
          
          for spec in self.specs:
              if spec.ismodule:
                  self.modules.append(Module(spec.name, spec.path, dsm=self))
              else:
                  self.packages.append(Package(
                      spec.name, spec.path,
                      dsm=self, limit_to=spec.limit_to,
                      build_tree=True,
                      build_dependencies=False,
                      enforce_init=self.enforce_init))
docs: Build the Python packages tree.