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

[Help]A workflow path state tranform error #162

Closed
AngelLiang opened this issue May 28, 2020 · 3 comments
Closed

[Help]A workflow path state tranform error #162

AngelLiang opened this issue May 28, 2020 · 3 comments

Comments

@AngelLiang
Copy link
Contributor

Hello, thank you for your project, it's a great project and I very like it. When I use it, I meet some problem.

I make a workflow path as follow:

图片

when I walk the path: draft -> issued -> received -> closed (order 3)
It's right and that's what I expected.

When I walk this path: draft -> issued -> part received -> received -> closed.
the actual path is this :draft -> issued -> part received -> received (order 2).

图片

I expect that I walk the path is this: draft -> issued -> part received -> received -> closed. But it seems finish at received state. It can't tranform from received state to closed state. I very strange for it.

Can someone help me? Thank you.

@javrasya
Copy link
Owner

javrasya commented Jun 2, 2020

Sorry for late response @AngelLiang , Let me test this flow today and get back to you.

javrasya added a commit that referenced this issue Jul 20, 2020
javrasya added a commit that referenced this issue Jul 20, 2020
@javrasya
Copy link
Owner

Hi @AngelLiang , there was a bug in django-river. The part which was canceling all impossible future transitions was misfunctioning. PR #168 should fix your problem when it is released.

Keep in mind that the bug has turned the Closed transition of your workflow to CANCELLED. So the workflow objects that have been created before this bug will still not be able to be closed. But those objects that are created after the patch will just be fine. If you want to make your previous objects work as well, you can do a manual operation that is changing the status of Transition and TransitionApproval objects in your DB to be PENDING, so they can transit to the CLOSED state.

I have also referred to your workflow in the feature test in the PR to be able to reproduce the bug, so hope you don't mind :-)

javrasya added a commit that referenced this issue Jul 20, 2020
…le future just because they are also in the future of impossible transition path
javrasya added a commit that referenced this issue Jul 20, 2020
… of one of those that is cancelled (#168)

* [#162] Don't cancel possible transitions even though it is the future of one of those that is cancelled

* [#162] Don't cancel those transitions that are actually in the possible future just because they are also in the future of impossible transition path
@javrasya
Copy link
Owner

The changes have been published in the django-river version 3.2.2 @AngelLiang . Please upgrade django-river version to be that one and let me know if your problem is still in place. Feel free to create a new ticket if so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants