Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connection Request Modal Popup Shows Wrong Workflow Status for Triggered Workflows #5658

Closed
2 tasks done
treusch opened this issue Oct 31, 2023 · 4 comments
Closed
2 tasks done
Labels
Fixed in v16.4 Status: Confirmed It's clear what the subject of the issue is about, and what the resolution should be. Type: Bug Confirmed bugs or reports that are very likely to be bugs.

Comments

@treusch
Copy link

treusch commented Oct 31, 2023

Description

On the modal pop up window for connection requests from the connections board and list view, when you expand the Workflows panel, the status displayed for workflows that have been triggered may not always contain the right status. Even when the workflow has completed, sometimes it will display "Running" as the status of the workflow.

Actual Behavior

Actual BehaviorIf the workflow action sets the status of the workflow to anything other than "Completed" when the workflow completes, the status displayed on the modal popup window for that workflow will be "Running", even if the workflow is actually complete.

This is what is displayed on the modal popup window.
image

The workflow Detail page shows that this workflow is actually complete.
image

The line of code causing the issue:
image

The fix:
image

This would allow the status to be based on whether the workflow has actually completed or not and would show any custom status messages Rock users have used in their workflows.

Expected Behavior

I would expect that the code would check for a completed date/time and if that is populated, it would show the actual status that was saved on the workflow.

If the completed date/time is not populated, then "Running" is an acceptable status to show, but even then, if the person who created the workflow writes statuses as the workflow progresses, it would be more helpful to display what that status is, rather than just "Running".

Steps to Reproduce

Create a connection type.
Create a connection opportunity of that type.
Create a workflow that can be triggered (manually is fine) from the connection opportunity or type.
In the workflow, make sure there is an activity with an action that completes the workflow but sets the status to something other than "Completed". We needed 3 different statuses 1) Completed - Internal 2) Completed - External and 3) Completed - No Source.

Trigger the workflow to run.
View the connection request on which the workflow ran. Expand the "Workflows" panel.
Even though the workflow is complete, the screen will show that the workflow is "Running".

Issue Confirmation

  • Perform a search on the Github Issues to see if your bug or enhancement is already reported.
  • Try to reproduce the problem on a fresh install or on the demo site.

Rock Version

13, 14, 15, 16 and 17

Client Culture Setting

en-US

@chead4
Copy link

chead4 commented Jan 23, 2024

@treusch I haven't been able to recreate the issue mentioned. If you are still having the issue, could you please provide an export of your workflow? This would help me to better understand your particular use case.

@treusch
Copy link
Author

treusch commented Jan 24, 2024

@chead4 My apologies. I am not sure why I wasn't getting notified of your comments. I see that the label "Not Yet Reproduced" was removed. Were you able to reproduce the issue or do you still need a workflow example exported?

@treusch
Copy link
Author

treusch commented Jan 24, 2024

@chead4 In case you still need it, I set up a workflow in the demo site. I ran that workflow from a connection request and you can see the results there.
Connection Request
Workflow Type
Workflow
I have attached the export of that workflow here.

GitHub Issue 5658_202401231905.json

The workflow has 2 actions in one activity. The first action just sets the Connection Request the workflow was launched from and the 2nd action just marks the workflow complete, but instead of using the status "Complete" I change it to "TestComplete" to show you that when you look at the workflows that have run on that connection request, Rock indicates that the workflow is still running, even though it is not.
WF26

CR1

Hope this helps. Thanks!

@sparkdevnetwork-service sparkdevnetwork-service added Status: Confirmed It's clear what the subject of the issue is about, and what the resolution should be. Type: Bug Confirmed bugs or reports that are very likely to be bugs. labels Jan 25, 2024
@chead4
Copy link

chead4 commented Jan 26, 2024

@treusch Thank you for the workflow export and additional details. I was able to recreate the issue and appreciate you getting back to me.

unlearnd added a commit that referenced this issue Mar 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Fixed in v16.4 Status: Confirmed It's clear what the subject of the issue is about, and what the resolution should be. Type: Bug Confirmed bugs or reports that are very likely to be bugs.
Projects
None yet
Development

No branches or pull requests

4 participants