Skip to main content

Python Replayer Adapter for Temporal workflows with debugging capabilities

Project description

Python Replayer Adapter for Temporal

A Python adapter for debugging and replaying Temporal workflows with breakpoint support.

Features

  • Workflow Debugging: Comprehensive interceptors for debugging workflow execution
  • Breakpoint Support: Set breakpoints for standalone mode or integrate with IDE debugger
  • Dual Modes: Support for both standalone (JSON file) and IDE-integrated replay modes
  • Activity Debugging: Interceptors for activity execution debugging

Installation

# Install in development mode
pip install -e .

# Or install with development dependencies
pip install -e .[dev]

Quick Start

Standalone Mode

from replayer_adapter_python import *

# Configure replay
set_replay_mode(ReplayMode.STANDALONE)
set_breakpoints([5, 15, 30])

# Replay workflow
opts = ReplayOptions(history_file_path="workflow_history.json")
replay(opts, YourWorkflowClass)

IDE Integration Mode

from replayer_adapter_python import *

# Set IDE mode (connects via WFDBG_HISTORY_PORT env var)
set_replay_mode(ReplayMode.IDE)

# Replay with IDE debugger
opts = ReplayOptions()
replay(opts, YourWorkflowClass)

API Reference

Core Functions

  • set_replay_mode(mode): Set replay mode (ReplayMode.STANDALONE or ReplayMode.IDE)
  • set_breakpoints(event_ids): Set breakpoints for standalone mode
  • replay(opts, workflow_class): Main replay function

Classes

  • ReplayOptions: Configuration for replay settings
  • RunnerWorkerInterceptor: Main interceptor for workflow debugging

Environment Variables

  • WFDBG_HISTORY_PORT: Port for IDE debugger communication (default: 54578)

Dependencies

  • temporalio>=1.15.0
  • requests>=2.32.0

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

temporal_replayer_adapter_python-1.0.0.tar.gz (12.4 kB view details)

Uploaded Source

Built Distribution

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

File details

Details for the file temporal_replayer_adapter_python-1.0.0.tar.gz.

File metadata

File hashes

Hashes for temporal_replayer_adapter_python-1.0.0.tar.gz
Algorithm Hash digest
SHA256 414b79af6bacd25ae07c8f095d0a3b7d967a47b02e7cd997491d76892e7ed163
MD5 177369ac80e052c00761ca9f05831cf9
BLAKE2b-256 08075967e5e100f8078b773a513df0cb767c67419b90ee9d620cc1a90be894cf

See more details on using hashes here.

File details

Details for the file temporal_replayer_adapter_python-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for temporal_replayer_adapter_python-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1c7145e0e3b26011795ab7964575f13e8986462682e283f2246f6e7729256249
MD5 83a744203337aa6f04eff2af0006d0a2
BLAKE2b-256 2307c8e4efd63db512ed3635846c3c59b7d8dc51e54c2176b9a42892304f1b36

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