Pasting a Local Variable within Custom Block causes visual glitch

1 sentence description of the problem: I was wondering why the keyboard kept closing on me when tapping the set variable’s parameter, then this happened (image below):

Steps to reproduce the problem every time:

  1. Create a local variable
  2. Create a custom block with a parameter
  3. Add a variable block
  4. Paste in the local variable in the block (the one used by the custom block)

I expected this to happen: the parameter to show as normal

But instead this happened: appeared as if it was part of the block

Screenshots/video & project link:


Your username: Crosbyman64

Device type, iOS version & Hopscotch version: iPad13,8 | iPadOS 16.1.1 | HS 3.58.0

I’m no expert, but I’m 100% sure this isn’t supposed to happen. The keyboard also closes automatically when the set variable block has no math operators.

9 Likes

The bug seems to be very inconsistent. It would take a miracle to reproduce this bug, unfortunately…

I basically had some value, then I placed them within some custom blocks to make it neater, then I edited the block to include parameters, then I encountered the bug. Does it happen every time? Probably not…

It also seems to fix itself after leaving the project. I was actually extremely lucky I captured this bug. Because I don’t think this will ever happen again unless we tried to get this bug…

6 Likes

there’s a lot of visual glitches in this version, i’ve seen 2
the one i still remember is Set Text to “60-(var-var)”. when i pressed “cut” on the entire equation, there’s “60” left (100% normal) but it’s background is purple instead of white, and i was unable to write in it again.

3 Likes

There’s only one way to tell if the bug is occurring, and that’s when the keyboard refuses to open when tapping the parameter of a set variable block.

I basically added an object, added a local variable, then created another object with its own local variable of the same name, then I used an object variable to share values to other objects, then I created yet another object (by duplicating the last object I made), then I created some custom blocks without parameters and copied and pasted the set variables inside (one time I accidentally moved one of the set variables inside a custom block, so I copied it from that custom block to another custom block). When I realized it wouldn’t work due to how custom blocks work with local var, I added a parameter to pass the local variable inside. I then copied and pasted the block in place of the old variable blocks, then I started to notice something off. Part of the code wasn’t working, even though it clearly looked like it should. Then when I tapped one of the set variable blocks to try and fix it, it wouldn’t open the keyboard. So I removed the variable, still wouldn’t open. So I decided to paste the variable from another set variable, and the glitch occurred. Leaving the project fixes the visual glitch, but there’s a chance you’ll notice another block where object variables look like local variables. It doesn’t affect every block, fortunately.

3 Likes

Thanks for making the bug report even if it can’t be consistently reproduced — it does help to narrow down the problem.

1 Like