anko icon indicating copy to clipboard operation
anko copied to clipboard

Data race when running scripts concurrently

Open brutella opened this issue 1 year ago • 3 comments

When I run multiple scripts concurrently, I get a data race when the global variables Packages and PackageTypes are accessed here and here.

I add and remove packages from env.Packages and env.PackageTypes before a script is executed. That's why I get a data race because the access to those global variables is not synchronised. I was able to fix this issue by allowing packages to be defined on an environment level – see pull request below.

Might be related to #34

brutella avatar Oct 13 '23 09:10 brutella

Thanks. Could you please add tests?

mattn avatar Oct 14 '23 00:10 mattn

Done

brutella avatar Oct 16 '23 09:10 brutella

@mattn Any chance to get this merged?

brutella avatar Nov 24 '23 09:11 brutella