Digital icon indicating copy to clipboard operation
Digital copied to clipboard

wires freak out and displace after taking a step back

Open The-Devil-Itself opened this issue 3 years ago • 18 comments

wires rearrange themself when ctrl-z has been used, it only happens if there are more than 80 components present

The-Devil-Itself avatar Feb 12 '22 11:02 The-Devil-Itself

Are you able to reproduce this issue? It seems to be a duplicate of #364. I can not reproduce this error despite all attempts. Therefore, I can not fix it. If you know a way to reproduce this problem I could finally solve it.

hneemann avatar Feb 12 '22 11:02 hneemann

you can reproduce it by making an 80+ component cicruit with wires, then move all of it from the original place to anywhere else, then ctrl z, and you'll see the displaced wires, i'm able to reproduce the issue

The-Devil-Itself avatar Feb 12 '22 11:02 The-Devil-Itself

Just tested: Open examples/sequential/conway/Conway.dig (1000+ components and wires), move any part or the compete circuit arround, press Ctrl-Z and no problem whatsoever.

hneemann avatar Feb 12 '22 11:02 hneemann

i was unable to reproduce it with any exmple,but there's a working instance of the bug

tinyest computer.dig.tar.gz

The-Devil-Itself avatar Feb 12 '22 11:02 The-Devil-Itself

When I open this circuit, and move parts of it or all of it, ctrl-z works without problems.

Are there any files named like Digital_2021-09-22_16-16-12.log in your home-folder? It is the same folder the file .digital.cfg is located.

hneemann avatar Feb 12 '22 12:02 hneemann

The simulator uses event-sourcing for the undo. So all changes since the last loading of the circuit are stored and if a step is to be undone, the original circuit is restored and all changes except the last one are executed again. It seems that it is somehow possible to make changes bypassing this system. If then an undo is executed, chaotic conditions arise. And I have no idea how a change can be made bypassing the event-sourcing system.

hneemann avatar Feb 12 '22 12:02 hneemann

where can i find this log in the linux version? bc i don't see any in the folder . or in an extended search through the file system

The-Devil-Itself avatar Feb 12 '22 12:02 The-Devil-Itself

On a linux system such a file is stored directly in the home folder. If there is none, none was created. Too bad!

hneemann avatar Feb 12 '22 12:02 hneemann

okay, i found some clue . it never happens, if the file has been saved. https://user-images.githubusercontent.com/99536568/153712370-eb5b8b91-6571-445f-8b63-561407c34904.mp4

The-Devil-Itself avatar Feb 12 '22 13:02 The-Devil-Itself

And it only happend to the oddly oriented wires, not any of the horizontal or vertical

The-Devil-Itself avatar Feb 12 '22 13:02 The-Devil-Itself

Thank you for the video! I have watched it many times and even more I have tried it with this circuit and here it works perfectly every time.

hneemann avatar Feb 12 '22 16:02 hneemann

I've experienced rare problems exactly like this going years back. I never figured out how to trigger it reliably but I do specifically recall it happening with diagonal wires in a large circuit.

xotmatrix avatar Feb 12 '22 19:02 xotmatrix

@The-Devil-Itself Are you able to replicate the problem reliably so that I could send you a possible fix to test?

hneemann avatar Feb 14 '22 20:02 hneemann

Yes, i will happily test it and i am able to replicate it reliably whenever i want to.

The-Devil-Itself avatar Feb 14 '22 22:02 The-Devil-Itself

Could you please try v0.29-5-g86af23b and v0.29-3-g32f924c you can find here?

I am not sure if any of the builds will fix the problem. Since I can't reproduce the bug, I essentially guessed. :-(

hneemann avatar Feb 15 '22 09:02 hneemann

it fixed it, i cant produce the problem in this build

The-Devil-Itself avatar Feb 15 '22 10:02 The-Devil-Itself

Which one does fix it?

hneemann avatar Feb 15 '22 10:02 hneemann

i can't produce it in any of the 2,so i think the earlier

The-Devil-Itself avatar Feb 15 '22 10:02 The-Devil-Itself