question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Question about multiple destination [concurrency]

See original GitHub issue

I know that multiple source is correct and defined as follow:

transition_1 =  {'trigger': 'jump', 'source': ['a','b'], 'dest': 'c'}

But when it comes to multiple destination, it’s wrong.

transition_2 = {'trigger': 'jump', 'source': 'a', 'dest': ['b','c']}

I don’t know how to implement using this library. Anyone can give me some ideas? or add this feature to this library? Welcome to discuss.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

4reactions
aleneumcommented, May 18, 2018

Since the above mentioned ‘workaround’ does not satisfy proper concurrency, I add ‘concurrent states’ as a feature for 0.7.0. This requires some significant changes in the nested states extension but I assume this tradeoff should be worth it since there is a lack of (Python) state machine libraries that support concurrency.

0reactions
aleneumcommented, Mar 20, 2020

transition 0.8.0 now supports parallel states as mentioned and illustrated in #371. Having parallel states is solved by using nested states with the parallel keyword.

Transitions with mutliple destinations are not supported though. I opted for the nested solution since this is how it is defined in state charts as far as I can tell and I could also not think of a custom transitions-way of definining scopes and how to determine when concurrent states should be exited again.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Java Multithreading Concurrency Interview Questions and ...
Java Multithreading Interview Questions and Answers · What is the difference between Process and Thread? · What are the benefits of multi-threaded ...
Read more >
Multithreading and Concurrency Interview Questions with ...
Multithreading and concurrency questions are an essential part of any ... Concurrency Interview Questions with Answers | Multiple Concepts.
Read more >
Interview Questions on Concurrency, GCD, Operation Queue
This is the part 6 of the series "Mastering Concurrency in iOS", and in this part, I've focused on interview questions related to ......
Read more >
Concurrency - Science topic
I am looking for some comprehensive survey over multi-version concurrency control techniques. Relevant answer.
Read more >
Concurrency Explained: How to Build a Multi-Threaded ...
Serial and concurrent affect the destination — the queue in which your work has been submitted to run. This is in contrast to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found