def getPythonDirectoryNames(directoryName):
 pythonDirectoryNames = []
 directory = os.listdir(directoryName)
 for fileName in directory:
  subdirectoryName = os.path.join(directoryName, fileName)
  if os.path.isdir(subdirectoryName):
   if os.path.isfile(os.path.join(subdirectoryName, '__init__.py')):
    pythonDirectoryNames.append(subdirectoryName)
 return pythonDirectoryNames

def getPythonDirectoryNames ( directoryName ) : pythonDirectoryNames = [ ] directory = os . listdir ( directoryName ) for fileName in directory : subdirectoryName = os . path . join ( directoryName , fileName ) if os . path . isdir ( subdirectoryName ) : if os . path . isfile ( os . path . join ( subdirectoryName , '__init__.py' ) ) : pythonDirectoryNames . append ( subdirectoryName ) return pythonDirectoryNames
get the python directories .