Skip to content

cli fails when workflow names aren't unique #1286

@doc-han

Description

@doc-han

Description

Apparently, multiple workflows in the same project could have the same name.
This causes the id(slugified string) generated for the colliding workflows to be the same.

Example:
A simple workflow (a-simple-workflow)

  • step 1
  • step 2

A simple workflow (a-simple-workflow)

  • step 2
  • step 3

With this setup. Searching for step 3 in the second workflow will actually perform the search in the first workflow where it doesn't exist.

Proposed solution.

When creating id(slugified string) for the workflows. we first search whether the workflow already exists, and if so we suffix it with a count.
With this we'll have

A simple workflow (a-simple-workflow)
A simple workflow (a-simple-workflow-1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLITracking issue to do with the CLI

    Type

    No type

    Projects

    Status

    Tech Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions