Skip to main content

A command-line interface for Dagster+

Project description

Dagster CLI (dgc)

A command-line interface for Dagster+, inspired by GitHub's gh CLI.

Installation

# Install with uv (recommended - adds 'dgc' to PATH)
uv tool install dagster-cli

# Or install with pip
pip install dagster-cli

Quick Start

# Authenticate with your Dagster+ deployment
dgc auth login

# Check health status of all assets (find problems)
dgc asset health

# View details about a specific asset
dgc asset view analytics/daily_revenue

# View logs for a failed run (see stack traces)
dgc run logs abc123 --stderr

# List recent runs to find failures
dgc run list --limit 10

Note: All commands support --help for detailed options and --tldr for quick examples.

MCP Server for AI Assistants

Run the MCP server without installation using uvx:

# Start MCP server for Claude Code integration
uvx --from dagster-cli dgc mcp start

Configure Claude Code by adding to your MCP settings:

{
  "mcpServers": {
    "dagster-cli": {
      "command": "uvx",
      "args": ["--from", "dagster-cli", "dgc", "mcp", "start"]
    }
  }
}

This enables AI assistants to:

  • Check asset health and identify failures
  • Investigate failed runs and view error logs
  • Monitor job execution and debug issues
  • Access stderr/stdout logs for troubleshooting

Working with Branch Deployments

# List all deployments including branches
dgc deployment list

# Get filtered logs from a branch deployment (e.g., for PR review)
dgc run list --deployment feat-new-feature --status FAILURE --limit 5
dgc run logs abc123 --deployment feat-new-feature --stderr

# Filter runs by job name on a specific deployment
dgc run list --deployment staging --job daily_etl --limit 10

Features

  • Secure Authentication - Store credentials safely with profile support
  • Job Management - List, view, and run Dagster jobs from the terminal
  • Run Monitoring - Track run status, view logs, and analyze failures
  • Asset Management - List, materialize, and monitor asset health
  • Repository Operations - List and reload code locations
  • Profile Support - Manage multiple Dagster+ deployments
  • Branch Deployment Support - Access branch deployments for testing and debugging
  • Deployment Discovery - List and test available deployments
  • MCP Integration - AI assistant integration for monitoring and debugging

Configuration

Authentication

dgc auth login                  # Set up credentials
dgc auth status                 # View current profile
dgc auth switch staging         # Switch between profiles

Multiple Profiles

dgc auth login --profile staging    # Create new profile
dgc job list --profile production   # Use specific profile

Environment Variables

  • DAGSTER_CLOUD_TOKEN - User token
  • DAGSTER_CLOUD_URL - Deployment URL
  • DGC_PROFILE - Default profile
  • DAGSTER_CLOUD_DEPLOYMENT - Default deployment

Credentials stored in ~/.config/dagster-cli/config.json

Development

# Run tests
uv run pytest

# Format and lint
make fix

# Build package
uv build

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

dagster_cli-0.8.1.tar.gz (32.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dagster_cli-0.8.1-py3-none-any.whl (45.4 kB view details)

Uploaded Python 3

File details

Details for the file dagster_cli-0.8.1.tar.gz.

File metadata

  • Download URL: dagster_cli-0.8.1.tar.gz
  • Upload date:
  • Size: 32.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.25 {"installer":{"name":"uv","version":"0.9.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for dagster_cli-0.8.1.tar.gz
Algorithm Hash digest
SHA256 1cbb338c3b97abc20985ab4617f7f16e09fce75c0eb845b52c02f18a1aeaee90
MD5 df5d9380b1d359d30e64c6da5cca5454
BLAKE2b-256 87b44a571312b614d8a21377ffce649103d92239a4c9215bb0fb54229072720c

See more details on using hashes here.

File details

Details for the file dagster_cli-0.8.1-py3-none-any.whl.

File metadata

  • Download URL: dagster_cli-0.8.1-py3-none-any.whl
  • Upload date:
  • Size: 45.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.25 {"installer":{"name":"uv","version":"0.9.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for dagster_cli-0.8.1-py3-none-any.whl
Algorithm Hash digest
SHA256 15db4715d3a3be89613d65813ef3b94f30eead074aced87f64a72298542f5034
MD5 61854dbebb0c0f051c6f8807ebcf7a78
BLAKE2b-256 241b255a7e6a1ac94dc852313a455c1e485ae7b67cd9f88326a2eb38670294f5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page