AWS Deadline Cloud Python Library (deadline)
raw JSON → 0.56.1 verified Fri May 01 auth: no python
Multi-purpose Python library and CLI tool for interacting with AWS Deadline Cloud. Provides job submission, asset management, job monitoring, and worker integration. Current version 0.56.1, actively maintained by AWS, releases bi-weekly to monthly.
pip install deadline Common errors
error ModuleNotFoundError: No module named 'deadline.client' ↓
cause Installed an old version (<0.50) where the package layout was different, or virtual environment misconfigured.
fix
Ensure you have a recent version:
pip install -U deadline. The package name is deadline, not deadline-cloud. error AttributeError: module 'deadline' has no attribute 'client' ↓
cause Using `import deadline` and then `deadline.client` but the package uses lazy imports or requires explicit import.
fix
Use
from deadline import client instead. error ImportError: cannot import name 'AssetSync' from 'deadline.job_attachments' ↓
cause AssetSync was removed in version 0.55.0 after deprecation in 0.54.1.
fix
Update code to use
from deadline import job_attachments and call job_attachments.api.sync_inputs(...) or similar new API. error botocore.exceptions.NoCredentialsError: Unable to locate credentials ↓
cause AWS credentials not configured or not passed to the Deadline client.
fix
Set environment variables
AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, and AWS_DEFAULT_REGION, or configure a profile. Warnings
breaking In version 0.55.0, job_attachments was decoupled from deadline.client. Old imports like `from deadline.job_attachments.asset_sync import AssetSync` will fail. Use `from deadline import job_attachments` instead. ↓
fix Replace any `from deadline.job_attachments.asset_sync` imports with `from deadline import job_attachments` and use the new API.
deprecated CLI option `bundle gui-submit --submitter-name` is deprecated in 0.54.0. Use `--submitter-info` instead. ↓
fix Replace `--submitter-name` with `--submitter-info` in CLI commands.
deprecated `AssetSync.sync_inputs` and `AssetSync.attachment_sync_inputs` are deprecated since 0.54.1 and will be removed in a future version. ↓
fix Use other public APIs under job_attachments (e.g., job_attachments.api).
deprecated `--timezone` deprecated in favor of `--timestamp-format` for the `job logs` CLI command since 0.53.3. ↓
fix Use `--timestamp-format relative` or `--timestamp-format utc` instead of `--timezone`.
gotcha The `client` module does not export a class `DeadlineClient`. It is a module with functions. ↓
fix Import as `from deadline import client` and call `client.get_deadline_client()`.
Imports
- deadline.client wrong
from deadline.client import DeadlineClientcorrectfrom deadline import client - deadline.job_attachments wrong
from deadline.job_attachments.asset_sync import AssetSynccorrectfrom deadline import job_attachments
Quickstart
import os
from deadline import client
# Set AWS credentials (or use default session)
os.environ['AWS_DEFAULT_REGION'] = 'us-west-2'
# Get a Deadline client instance
# Note: client.get_deadline_client() returns a low-level boto3 client
# For high-level operations, use deadline.job_attachments or deadline.jobs
farm_id = 'farm-1234567890abcdef0'
queue_id = 'queue-1234567890abcdef0'
dl_client = client.get_deadline_client()
# List jobs
response = dl_client.list_jobs(farmId=farm_id, queueId=queue_id)
print(response)