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

parallel does not work as expected #1430

Open
bernhardreisenberger opened this issue Dec 4, 2019 · 1 comment
Open

parallel does not work as expected #1430

bernhardreisenberger opened this issue Dec 4, 2019 · 1 comment
Labels

Comments

@bernhardreisenberger
Copy link
Contributor

Hi,

When using equals in a sequence, and executing a subsequence in parallel, the actions in this subsequence are only executed in parallel when i wrap the subsequence in square brackets.

[
equals(state.foo),
{
// not wrapped in [] -> wrong behavior
bar: parallel([sayHey, sayHo])
}
]

[
equals(state.foo),
{
// wrapped in [] -> correct behavior
bar: [parallel([sayHey, sayHo])]
}
]

see https://codesandbox.io/s/parallel-bug-pi1mc for an example.

Not using equals, both sequences (wrapped and unwrapped) will behave the same.
It is a minor issue, but one to easily trip over.

@christianalfoni
Copy link
Member

Oh, very interesting! I will look into this, thanks! 😄

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

No branches or pull requests

2 participants