Skip to content

When deserializing typed search attributes, invalid values should be ignored #1668

Open
@cretz

Description

@cretz

Expected Behavior

If a user creates a workflow or a schedule using untyped attributes and passes in a single-item array, the typed search attributes should simply not include that value.

Actual Behavior

Today, if a user creates a workflow or schedule using untyped attributes like keyword with a single-item array, it is a panic when we try to convert to typed search attributes. While it may seem like inside a workflow this panic is the users fault for accessing typed search attributes, it is not the users fault when simply describing the workflow. We might as well just ignore all invalid values. This is confirmed to be the behavior in Python (didn't confirm elsewhere).

This was most obvious when a user used the TypeScript SDK to create a schedule that has a workflow action with its search attributes as a single item array (the only form TypeScript SDK supports at this time since it lacks typed search attributes). Then the user did a temporal schedule describe in CLI which panics.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions