Fetching contributors…
Cannot retrieve contributors at this time
42 lines (25 sloc) 1.24 KB

Managing Packages

Any configuration related to packages is done through the Packages object. Here is an example showing some common operations:

def main(build):
    # it's possible to set the index urls that packages will be installed from:
    build.packages.index_urls = [""]

    # this method installs the package "py.test" with version 2.7.0. It's
    # available in the sandbox as soon as the package is installed.
    build.packages.install("py.test", version="==2.7.0")

    # if you want to a development / editable egg, you can use this function.
    build.packages.install(".", develop=True)

    # if you want to set a specific version of a package to download, you can do so with versions
        "requests": "==2.6.0"

    # this takes effect on all subsequent installations. For example, it will be considered here:

Full API Reference

.. autoclass:: uranium.packages.Packages