Open j-martin opened 4 years ago
Happy to accept PRs to fix this - ideally we'd just pick the workflow based on the project. I personally can't contribute much here since we only use a single workflow across all projects.
I think if you set the org-clubhouse-workflow-name
to something invalid you should be able to reproduce the issue. As far as I am concerned #19 is good enough for me.
https://github.com/glittershark/org-clubhouse/pull/19 is a workaround the issue (before nothing would work).
Step to replicate:
org-clubhouse-workflow-name
variable.org-clubhouse-headline-from-story-id
(or any function that fetches stories) and pass the story id.Result:
Without https://github.com/glittershark/org-clubhouse/pull/19: The function fails to run. With https://github.com/glittershark/org-clubhouse/pull/19: the heading gets created, but the state of the headline is
UNKNOWN
.Expected:
The right state name is used regardless of the workflow used by the story.
A quick fix would be to flatten the list of states for all workflows instead of picking only the
org-clubhouse-workflow-name
inorg-clubhouse-workflow-states
, but what would make the state picker much less useful; too many states and most of these states would be rejected by the API since they may not belong to the project workflow.BAM! Now handling this is a feature request and not a bug. :P