UNDO - MAJOR Bug

Avatar
  • updated

There is a major bug that may cause a lot of problem ..just imagine you move a file using teracopy and undo the action ( using Ctrl+Z or Right click in Windows Explorer and choose Undo ) , Windows explorer totally wipes your moved files instead of returning those back to original place .. it is happening because teracopy failes to update the undo history of explorer , so explorer's undo doesn't undo the teracopy action ..


DON'T USE UNDO while using teracopy as file handler otherwise you will loss your files

Avatar
lj h

Yes, this happened to me.

Scenario:

1. Create folder

2. Rename folder created in (1)

3. Move files using TeraCopy into folder created in (1)

4. Accidentally trigger a Windows Explorer "Undo" action twice

5. The files are gone because Windows Explorer didn't record the move (3), TeraCopy did, so the 2 "Undo" actions reversed step (2) and step (1), thus the files were still in the folder and the folder is now gone

Luckily the files were inconsequential, but it took me a long time to figure out what happened, and I still have no idea how I triggered "Undo"

Is there really no fix for this? Seems like a massive oversight/bug

Thanks

Avatar
David Fernández

Yes. The bug is named Windows.

As you do not try undo an action done in Word with Open Office, do not try to undo an action made with an application with explorer.

It is called logical sense.

NEVER EVER undo anything on Windows. Just make the opposite action. If you move something, just redo the move the opposite way. Or be prepared... as you have just discovered.


If you make a folder in explorer, launch an application and the aplication writes a log file to that folder and then you undo in explorer, what do you think explorer will do? It will delete the folder and leave the file orphan because it did not know anything about what another application did.

File undo is just an aberration on Windows.

Avatar
fedir lavryk
Quote from David Fernández

Yes. The bug is named Windows.

As you do not try undo an action done in Word with Open Office, do not try to undo an action made with an application with explorer.

It is called logical sense.

NEVER EVER undo anything on Windows. Just make the opposite action. If you move something, just redo the move the opposite way. Or be prepared... as you have just discovered.


If you make a folder in explorer, launch an application and the aplication writes a log file to that folder and then you undo in explorer, what do you think explorer will do? It will delete the folder and leave the file orphan because it did not know anything about what another application did.

File undo is just an aberration on Windows.

This is all good words for little use. The undo call WILL occasionally happen by users.

Moreover, there is no undo button in the Teracopy interface either!

Avatar
nima
Quote from David Fernández

Yes. The bug is named Windows.

As you do not try undo an action done in Word with Open Office, do not try to undo an action made with an application with explorer.

It is called logical sense.

NEVER EVER undo anything on Windows. Just make the opposite action. If you move something, just redo the move the opposite way. Or be prepared... as you have just discovered.


If you make a folder in explorer, launch an application and the aplication writes a log file to that folder and then you undo in explorer, what do you think explorer will do? It will delete the folder and leave the file orphan because it did not know anything about what another application did.

File undo is just an aberration on Windows.

I have resolved this problem and posted the solution but the moderator didn't approve my post

anyway every program has its own clipboard stack, so if you disable undo for explorer it won't make conflict with Microsoft Word undo for example.

if you want to use TeraCopy you must disable Undo Option on your Windows Explorer

Avatar
momaks

This problem is caused by lazy opinionated programmers as it was an option that was available and fully functional (with all versions of windows) in all former versions of Teracopy. Suddenly it does not work and everyone is blaming windows. I believe that this is an essential part of teracopy that has been removed for no real reason. The only reason I updated was to gain speed in copying/moving but that option is not worth it if I have to sacrifice undo.

Avatar
David Fernández

The only way of trusting an undo critical data operation is displaying before doing it the complete stack of "undoing" operations to be performed. When you have dozens of windows opened, multiple remote connections opened and multiple operations ongoing there's no chance for windows to really know what I'm trying to "undo", and I can have no way of telling what to undo from any undo stack as I cannot see that stack. So undo is simply an aberration and prone to corrupt data.

The only logical operation is to know what you are doing and redo the opposite operation.

If someone thinks that undo was working on previous versions then it is ok. Please ask the developer to try to study if something has changed between those versions and to try to fix it. I will not trust it in any way.

Do you know that if you are copying files in one remote desktop connection and try to copy files to another remote connection the first connection simply breaks? And in that operation Teracopy is not involved. Perhaps Windows is not able to manage stacks for several windows/connections so it may not have anything to do with Teracopy, but with Windows itself... Just my 2 cents...

From ninjacode blog I found this and totally agree with:

-------------

If you press Ctrl+Z while Windows Explorer is in focus (this includes the taskbar and desktop), you will Undo the last file operation such as a delete, rename, move, or copy. The same goes for Ctrl+Y and Redo.

This is, of course, intended behaviour, but the way I work I'm always looking back and forth between open instances of Windows Explorer and e.g. a code editor arranged on multiple displays. If I do something in the Windows Explorer window, look back at the code editor window, and decide to undo an edit to the code, I might press Ctrl+Z without remembering to put the code editor window in focus first. The Windows Explorer window, up as it is on my other display and completely out of mind, would still be in focus and receive the Ctrl+Z hotkey, reversing a file operation I may have done hours ago.

Worse, this happens silently, so I might not even notice that it happened at all, until later when the un-deleted, un-copied, un-moved, or un-renamed file is needed and disaster ensues

------------


Avatar
momaks

I truely think that you are on something or English was never your first language. My initial questions/remarks concerned the removal of items on the list on teracopy BEFORE I click on start to copy/move the files. Before the initial process is started and when I am deciding on whether I want to move/copy a file. An example would be when there are many items to be transferred in a folder but just 1 or 2 need to be omitted. Rather than slowly work through placing each item one at a time onto teracopy, I would normally move the full folder onto teracopy, then remove the files or sub folders I did not want to move/copy and then started the move/copy process. It works in all prior versions of Teracopy, with all versions of Microsoft Windows except for versions 3.x.x of teracopy onwards. I hope this helps you understand. That is if you are willing to understand.

Avatar
David Fernández
Quote from momaks

I truely think that you are on something or English was never your first language. My initial questions/remarks concerned the removal of items on the list on teracopy BEFORE I click on start to copy/move the files. Before the initial process is started and when I am deciding on whether I want to move/copy a file. An example would be when there are many items to be transferred in a folder but just 1 or 2 need to be omitted. Rather than slowly work through placing each item one at a time onto teracopy, I would normally move the full folder onto teracopy, then remove the files or sub folders I did not want to move/copy and then started the move/copy process. It works in all prior versions of Teracopy, with all versions of Microsoft Windows except for versions 3.x.x of teracopy onwards. I hope this helps you understand. That is if you are willing to understand.

I suppose that you are referring to your comment in the "GUI overhaul" thread. If not, then I can't follow you and I'm totally lost.

If you read my post on that thread, you can see that I say that YOU CAN DELETE FILES FROM THE COPY LIST BEFORE COPYING, but it can only be done one by one and not by multiselecting them.

Also, are you the same user that initiated that thread? I can't say that because you have a different username, but you answered after I replied the OP. Are you replying in its name? Are you the same user?