Shopify Flow: Run Code does not understand Math.random()

In Shopify Flow, when using the action node ‘Run Code’ (used to run JavaScript), if I try to generate a random float with Math.random(), for some reason it always returns the same float on every single attempt: 0.8549251903236059

Is this a known issue?

See https://help.shopify.com/en/manual/shopify-flow/reference/actions/run-code#limitations

It’s blocked on purpose to prevent crypto mining.

1 Like

That is unfortunate to hear. Thanks for letting me know Paul