def find_packages():
 excludes = ['deathrow', 'quarantine']
 packages = []
 for (dir, subdirs, files) in os.walk('IPython'):
  package = dir.replace(os.path.sep, '.')
  if any((package.startswith(('IPython.' + exc)) for exc in excludes)):
   continue
  if ('__init__.py' not in files):
   continue
  packages.append(package)
 return packages

def find_packages ( ) : excludes = [ 'deathrow' , 'quarantine' ] packages = [ ] for ( dir , subdirs , files ) in os . walk ( 'IPython' ) : package = dir . replace ( os . path . sep , '.' ) if any ( ( package . startswith ( ( 'IPython.' + exc ) ) for exc in excludes ) ) : continue if ( '__init__.py' not in files ) : continue packages . append ( package ) return packages
return a list all python packages found within directory where where should be supplied as a "cross-platform" path; it will be converted to the appropriate local path syntax .