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.2.tar.gz (12.5 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.2.tar.gz.

File metadata

File hashes

Hashes for temporal_replayer_adapter_python-1.0.2.tar.gz
Algorithm Hash digest
SHA256 05c31e4e1f5267f6ad10d32ed19606be4b7fe01f066aa84fe61e76f98a419b70
MD5 a39c3b0f1feb6352de133fb6b8a2f581
BLAKE2b-256 e7560ab334cc5e55888298abb9d3e311b0e9d935bdaf194b4f7d9bc0e2768bd0

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for temporal_replayer_adapter_python-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d4e8cecd5b3af649adf8ea3f97663fd08ce3a0817c76fd814f88250ddd492c35
MD5 985fe36dd9a386959d10ff38c90221fc
BLAKE2b-256 8dc029338798bec54d3483f5b861dd32ae5d6520ca0cee2b8d4a2aab4b741cd9

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