Skip to content

Preserve output and custom status in v1 status query shims #231

Description

@andystaples

Summary

Fix payload-fetch semantics in the v1-compatible get_status(), get_status_all(), and get_status_by() methods.

Current behavior

get_status(show_input=False) maps show_input directly to durabletask's fetch_payloads flag. The underlying protocol flag is getInputsAndOutputs, so False removes not only input but also output, custom status, and failure details.

The collection shims call get_all_orchestration_states() with the default OrchestrationQuery(fetch_inputs_and_outputs=False), which can similarly omit payload data expected from the v1 status response.

This means the default v1-compatible calls can return completed or failed statuses without their output or custom status.

Expected behavior

Compatibility shims should fetch the payload data required to reproduce the v1 response, then apply v1-specific projection locally:

  • show_input=False suppresses only input;
  • output remains available for completed instances;
  • custom status remains available;
  • failure details remain available and continue to populate the compatibility output where applicable;
  • get_status_all() and get_status_by() return their expected payload fields.

Native durabletask APIs and their payload-fetch defaults should remain unchanged.

Acceptance criteria

  • Default get_status() retains output, custom status, and failure details while omitting input.
  • show_input=True includes input as well.
  • get_status_all() and get_status_by() retain v1-compatible payload fields.
  • Missing instances remain falsy as today.
  • Tests cover running, completed, and failed orchestration states without changing native client defaults.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions