![]()  | 
  
    Rosetta
    2019.12
    
   | 
 
Classes | |
| class | ContextualZipFile | 
Functions | |
| def | _python_cmd | 
| def | _install | 
| def | _build_egg | 
| def | archive_context | 
| def | _do_download | 
| def | use_setuptools | 
| def | _conflict_bail | 
| def | _unload_pkg_resources | 
| def | _clean_check | 
| def | download_file_powershell | 
| def | has_powershell | 
| def | download_file_curl | 
| def | has_curl | 
| def | download_file_wget | 
| def | has_wget | 
| def | download_file_insecure | 
| def | get_best_downloader | 
| def | download_setuptools | 
| def | _build_install_args | 
| def | _parse_args | 
| def | _download_args | 
| def | main | 
Variables | |
| USER_SITE = None | |
| string | DEFAULT_VERSION = "33.1.1" | 
| string | DEFAULT_URL = "https://pypi.io/packages/source/s/setuptools/" | 
| DEFAULT_SAVE_DIR = os.curdir | |
| string | DEFAULT_DEPRECATION_MESSAGE = "ez_setup.py is deprecated and when using it setuptools will be pinned to {0} since it's the last version that supports setuptools self upgrade/installation, check https://github.com/pypa/setuptools/issues/581 for more info; use pip to install setuptools" | 
| string | MEANINGFUL_INVALID_ZIP_ERR_MSG = 'Maybe {0} is corrupted, delete it and try again.' | 
      
  | 
  private | 
Build Setuptools egg.
References _python_cmd(), and archive_context().
Referenced by _do_download().
      
  | 
  private | 
Build the arguments to 'python setup.py install' on the setuptools package. Returns list of command line arguments.
Referenced by main().
      
  | 
  private | 
Run the command to download target. If the command fails, clean up before re-raising the error.
Referenced by download_file_curl(), download_file_powershell(), and download_file_wget().
      
  | 
  private | 
Setuptools was imported prior to invocation, so it is unsafe to unload it. Bail out.
Referenced by use_setuptools().
      
  | 
  private | 
Download Setuptools.
References _build_egg(), _unload_pkg_resources(), download_setuptools(), pyrosetta.tests.distributed.test_dask.format, and use_setuptools().
Referenced by use_setuptools().
      
  | 
  private | 
Return args for download_setuptools function from cmdline args.
Referenced by main().
      
  | 
  private | 
      
  | 
  private | 
Parse the command line for options.
Referenced by main().
      
  | 
  private | 
Execute a command. Return True if the command succeeded.
Referenced by _build_egg(), and _install().
      
  | 
  private | 
Referenced by _do_download(), and use_setuptools().
| def ez_setup.archive_context | ( | filename | ) | 
Unzip filename to a temporary directory, set to the cwd. The unzipped target is cleaned up after.
Referenced by _build_egg(), and _install().
| def ez_setup.download_file_curl | ( | url, | |
| target | |||
| ) | 
References _clean_check().
| def ez_setup.download_file_insecure | ( | url, | |
| target | |||
| ) | 
Use Python to download the file, without connection authentication.
References basic::database.open().
| def ez_setup.download_file_powershell | ( | url, | |
| target | |||
| ) | 
Download the file at url to target using Powershell. Powershell will validate trust. Raise an exception if the command cannot complete.
References _clean_check().
| def ez_setup.download_file_wget | ( | url, | |
| target | |||
| ) | 
References _clean_check().
| def ez_setup.download_setuptools | ( | version = DEFAULT_VERSION,  | 
        |
download_base = DEFAULT_URL,  | 
        |||
to_dir = DEFAULT_SAVE_DIR,  | 
        |||
delay = 15,  | 
        |||
downloader_factory = get_best_downloader  | 
        |||
| ) | 
Download setuptools from a specified location and return its filename. `version` should be a valid setuptools version number that is available as an sdist for download under the `download_base` URL (which should end with a '/'). `to_dir` is the directory where the egg will be downloaded. `delay` is the number of seconds to pause before an actual download attempt. ``downloader_factory`` should be a function taking no arguments and returning a function for downloading a URL to a target.
Referenced by _do_download(), get_best_downloader(), and main().
| def ez_setup.get_best_downloader | ( | ) | 
References download_setuptools().
| def ez_setup.has_curl | ( | ) | 
References basic::database.open().
| def ez_setup.has_powershell | ( | ) | 
Determine if Powershell is available.
References basic::database.open().
| def ez_setup.has_wget | ( | ) | 
References basic::database.open().
| def ez_setup.main | ( | ) | 
Install or upgrade setuptools and EasyInstall.
References _build_install_args(), _download_args(), _install(), _parse_args(), and download_setuptools().
| def ez_setup.use_setuptools | ( | version = DEFAULT_VERSION,  | 
        |
download_base = DEFAULT_URL,  | 
        |||
to_dir = DEFAULT_SAVE_DIR,  | 
        |||
download_delay = 15  | 
        |||
| ) | 
Ensure that a setuptools version is installed. Return None. Raise SystemExit if the requested version or later cannot be installed.
References _conflict_bail(), _do_download(), and _unload_pkg_resources().
Referenced by _do_download().
| string ez_setup.DEFAULT_DEPRECATION_MESSAGE = "ez_setup.py is deprecated and when using it setuptools will be pinned to {0} since it's the last version that supports setuptools self upgrade/installation, check https://github.com/pypa/setuptools/issues/581 for more info; use pip to install setuptools" | 
| ez_setup.DEFAULT_SAVE_DIR = os.curdir | 
| string ez_setup.DEFAULT_URL = "https://pypi.io/packages/source/s/setuptools/" | 
| string ez_setup.DEFAULT_VERSION = "33.1.1" | 
| string ez_setup.MEANINGFUL_INVALID_ZIP_ERR_MSG = 'Maybe {0} is corrupted, delete it and try again.' | 
| ez_setup.USER_SITE = None | 
 1.8.7