For loops - value becoming value2

I’ve got some for loops which sometimes change and sometimes do not change if code written in Blocks goes to JavaScript mode and back. When multiple for loops with value are used, sometimes these get converted into unique names, e.g. value2 and value3. I have a case where the “unique-ifier” has done a half-job and performed a partial search-and-replace on the usage inside the for loop.

It would be interesting to hear if others have experienced this and if anyone has worked out when this bug strikes?

Could this be partly related to using the sprite x block on a tile? That’s been working for a while but that’s what failed to convert from value to value3.