Skip to main content

Run Python jobs on the cloud using DISCO

Project description Python SDK

Coverage Status

This package lets you run jobs on platform from a Python program.

Using the SDK, you can create computing jobs, run them on, and get their results to your local machine. It is possible to offload any kind of Python program to be run on


  1. An account.

  2. Python version 3.6 and up.

  3. Python SDK installed:

    $ pip install disco


import disco
import pathlib

disco.set_credentials('', 'my_password', save_to_config=True)

my_file_id = disco.upload_file('', pathlib.Path('/home/bob/'))
job = disco.Job.create(my_file_id)

(task_result,) = job.get_results(block=True)

The code above uploads the file /home/bob/, runs it on cloud, waits for the job to finish, and writes the results to /home/bob/my_result.

When the job has been created, you can see it listed in list_jobs():

>>> import disco
>>> disco.Job.list_jobs())
[{'id': '5d650d25179854000d72b8cc', 'archived': False, 'name': 'd08e3e029bfc412ebc316e21f1a7dae0', 'status': 'Done', 'taskStates': ['Success']}]

This functions returns an instance of Job, which gives access to many useful operations on a job (see the API documentation).

Environment variables

The disco package supports these environment variables:

  • DISCO_BASE_URL - base URL of the server. Default:
  • DISCO_EMAIL - user's email to for authenticating with the server.
  • DISCO_PASSWORD - password for authenticating with the server.
  • DISCO_LIVE_TESTS - set true to run our live tests.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

disco-1.40.4.tar.gz (70.6 kB view hashes)

Uploaded source

Built Distribution

disco-1.40.4-py3-none-any.whl (102.8 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page