Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Undo/Redo stop working, only resume working after a reset #4152

Closed
muk0r opened this issue Nov 21, 2022 · 26 comments · Fixed by #4169, #4202 or #4230
Closed

Undo/Redo stop working, only resume working after a reset #4152

muk0r opened this issue Nov 21, 2022 · 26 comments · Fixed by #4169, #4202 or #4230
Labels
Prio:1 Highest priority: Crash or crippling bugs, features that enable new ways of working Type:Bug Errors and problems
Milestone

Comments

@muk0r
Copy link

muk0r commented Nov 21, 2022

on TrenchBroom 2022.2, multiple users have reported that Undo/Redo stop working through keyboard shortcut AND menu option.

They only resume working after closing and restarting TB.

No steps to reproduce are known.

@SatansFather
Copy link

I've had this happen a few times on 2021.1 so it definitely isn't caused by more recent changes.

@wedge-one
Copy link

I also reported this on Discord, been using TB extensively and for long periods of time, this never happened to me on 2022.1 or any older version, and it's been happening to me quite often.

I'm still not quite sure on how to reproduce this but, I thought it could be something related to using TB for long periods, however, this just happened to me not long after I had to restart the editor for the same reason, and I had just used the vertex clipping tool - using keyboard shortcut - and with CTRL + Enter to change the cut orientation. Could be related. Couldn't exactly reproduce but I'll keep trying.

@kduske kduske added Prio:1 Highest priority: Crash or crippling bugs, features that enable new ways of working Type:Bug Errors and problems labels Nov 25, 2022
@kduske kduske added this to the 2022.3 milestone Nov 25, 2022
@bstordeur
Copy link

Yeah I'm getting this a lot as well, but no idea what triggers it for now. :(

@kduske
Copy link
Collaborator

kduske commented Nov 27, 2022

Does any of you remember what the undo and redo menu items read exactly? Was it just "Undo", or "Undo " - if the latter, what command was it?

Also, if you run into this again, please report this info here - just write down what the undo and redo menu items said exactly.

@kduske
Copy link
Collaborator

kduske commented Nov 27, 2022

At the bottom of this page there are builds of current master where I have enabled logging of all commands and transactions. You will find that the log window will contain a lot of information.

If you want to help debug this issue, please try to run this build and if you notice that Undo is disabled, just copy and paste the last 50 or so lines from the log panel here. Additionally, please write down what the menu items say exactly, e.g. "Undo " or just "Undo" for both undo and redo. Thanks!

@wedge-one
Copy link

Gonna try this build.

I'm almost sure it's something related to brush editing: either resizing, clipping, moving... because I was having this issue while I was heavily editing the map geometry. When I stopped doing brush work and started working with entities, this issue didn't occur.

@wedge-one
Copy link

wedge-one commented Dec 11, 2022

Took me a while but it happened

Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Starting transaction ''
Command 'Translate Objects' executed
Committing transaction
Transaction 'Translate Objects' executed
Committing transaction
Transaction 'Duplicate Objects' executed <--- it was at this point where I tried to Undo and it didn't work

And this is also the end of the log. After that just a save entry.

@kduske
Copy link
Collaborator

kduske commented Dec 11, 2022

Thanks! Do you remember what the title of the undo and redo menu items was?

@wedge-one
Copy link

I checked, could see just "Undo" and "Redo", if it had a space like "Undo " I couldn't spot.

@wedge-one
Copy link

Again, doing different things:

Starting transaction 'Select Object'
Command 'Select 1 Object' executed
Committing transaction
Transaction 'Select Object' executed
Starting transaction 'Select Object'
Command 'Select 1 Object' executed
Committing transaction
Transaction 'Select Object' executed
Starting transaction 'CSG Convex Merge'
Command 'Select None' executed
Starting transaction 'Add Objects'
Command 'Add Objects' executed
Command 'Ensure Objects Visible' executed
Command 'Unlock Objects' executed
Committing transaction
Transaction 'Add Objects' executed
Starting transaction ''
Command 'Remove Objects' executed
Committing transaction
Transaction 'Remove Objects' executed
Command 'Select 1 Object' executed
Committing transaction
Transaction 'CSG Convex Merge' executed
Starting transaction 'Turn Selection into Detail'
Starting transaction ''
Command 'Change Face Attributes' executed
Committing transaction
Transaction 'Change Face Attributes' executed
Committing transaction
Transaction 'Turn Selection into Detail' executed
Command 'Select None' executed

image

@bstordeur
Copy link

@kduske pains me to say it, but this is still present in TrenchBroom 2023.1 Build v2023.1-RC1 Release Win64. :(

I've been having it regularly when using lots of nested Linked Groups, still don't know how to reproduce it...
image

@kduske kduske reopened this Feb 12, 2023
@wedge-one
Copy link

wedge-one commented Feb 13, 2023

I must be using a different RC version (RC1-3?). Been using it extensively and the issue has not occurred once. Already reported to @kduske about it.

[EDIT] I hate myself. As soon as I posted this, the issue occurred for the first time. I'm not kidding. Alt tabbed back to TB, hit Ctrl Z, and gone...

@kduske
Copy link
Collaborator

kduske commented Feb 13, 2023

[EDIT] I hate myself. As soon as I posted this, the issue occurred for the first time. I'm not kidding. Alt tabbed back to TB, hit Ctrl Z, and gone...

Does that mean that Undo was disabled after you hit CTRL+Z or that you fixed a disabled undo by alt-tabbing and hitting CTRL+Z?

@bstordeur
Copy link

One interesting thing to note maybe, is that when it happened for me just now, the linked group also stopped updating as usual (we had this issue a while back) like if I delete a brush from inside one group, the others won't update until I move a brush, which is not the usual behaviour.
I still can't reproduce it reliably, but I've been getting it quite often when using complex linked group setups.

@kduske
Copy link
Collaborator

kduske commented Feb 14, 2023

It could be an unhandled exception during a transaction that leads to the transaction not being closed properly. Here's a build that will throw an error if this occurs: https://github.com/TrenchBroom/TrenchBroom/actions/runs/4178495422

Once the builds are finished, could you please try that? Please save often as it will crash if I'm right.

@wedge-one
Copy link

[EDIT] I hate myself. As soon as I posted this, the issue occurred for the first time. I'm not kidding. Alt tabbed back to TB, hit Ctrl Z, and gone...

Does that mean that Undo was disabled after you hit CTRL+Z or that you fixed a disabled undo by alt-tabbing and hitting CTRL+Z?

Right after I wrote that reply, I alt+tabbed back to TB and the Undo stopped working. But yesterday it didn't occur. It's been very rare.

I don't use Linked Groups but I'm always using groups and editing inside them.

@kduske
Copy link
Collaborator

kduske commented Feb 19, 2023

@wedge-one @bstordeur has either of you tried out the build I linked above?

@bstordeur
Copy link

I've switched to it but haven't had much mapping time last few days. Hopefully I can get some time in today.

@wedge-one
Copy link

I had totally forgotten, when I clicked the link it was still building.

I'm still using that old build, doing a lot of mapping and didn't get the issue once after that only one time. And sometimes I have more than one instance of TB running and no issues. If I hadn't had that issue that day, I would say it was fixed in my end.

Gonna try this build right now and tell you the results.

@wedge-one
Copy link

Issue just occurred, not long after opening my map. Yesterday worked just fine with a long mapping session.

Didn't catch exactly when it happened, but some of my recent actions were (in order):

  • Clipping a bunch of brushes with clipping tool
  • Joining some
  • Turning into Detail
  • Resizing
  • More detail
  • Cutting with Ctrl+Shift drag
  • Alt+Click to apply texture
  • Resize brush
  • Undo is gone 🤷‍♂️

@kduske
Copy link
Collaborator

kduske commented Feb 20, 2023

Were you using the build I linked above?

@wedge-one
Copy link

Were you using the build I linked above?

Yes, TrenchBroom-Win64-v2023.1-RC1-19-gc1e246c51-Release

@kduske
Copy link
Collaborator

kduske commented Feb 20, 2023

Ah, that's interesting, so it wasn't an unhandled exception in your case.

@wedge-one
Copy link

Just a follow-up: used the same instance of TB yesterday for the whole day, did all kinds of operations, and no Undo issue.

@kduske kduske modified the milestones: 2023.1, Next Mar 23, 2023
@eGax
Copy link
Contributor

eGax commented Mar 28, 2023

I just had a report from ComfyByTheFire on the Quake Mapping Discord it is still happening for them on 2023.1.

@kduske
Copy link
Collaborator

kduske commented Apr 14, 2023

I think I finally found the cause of this and have fixed it. I'm closing this, but if it happens again after the next release, let me know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Prio:1 Highest priority: Crash or crippling bugs, features that enable new ways of working Type:Bug Errors and problems
Projects
None yet
6 participants