initialState() does not work beyond machine load
Nobody has claimed this yet.
- Dominant language
- Dart
- Stars
- 53
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
https://github.com/panghy/fsm2/commit/d7a24380178bd5cdc3b585ac34423a5b9086a158
Even though the generated visualization of the FSM suggests that entering a parent state will automatically also activate its child state (prescribed by initialState<S>()). In reality, the automated activation of child initialState() only works on initial load of the FSM.
Perhaps there could have been a different way to indicate that subsequent entry of the parent state should also trigger transition to a child state (perhaps instead of initialState<S>(), one could imagine declaring activateChild<S>(), with the bonus of coregions automatically activating multiple children on entry, without the need for onFork()).
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing commit d7a24380178bd5cdc3b585ac34423a5b9086a158 and reproducing the difference between initial FSM load and later entry into a parent state. Compare the generated visualization with runtime behavior, then define and verify the expected child activation semantics for subsequent parent-state entry.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dart
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100