postmanlabs / postman-app-support

Postman is an API platform for building and using APIs. Postman simplifies each step of the API lifecycle and streamlines collaboration so you can create better APIs—faster.
https://www.postman.com
5.84k stars 839 forks source link

Moving a folder to another collection *sometimes* creates a linked copy instead of moving #12519

Open cbecker-jwu opened 11 months ago

cbecker-jwu commented 11 months ago

Is there an existing issue for this?

Describe the Issue

I was trying to cleanup reorganize my Postman Workspace, and suddenly realized that some of my folders and requests were just completely gone.

It took a while to realize what was going on. Now I've seen exactly what was happening, I just don't know why.

One thing I was doing, was creating a new collection, sort of an archive of older collections that I wasn't currently using. To do so, I would create a folder in the new collection, and copy or move the folders/requests from the old collection into the subfolder in my new Archive collection.

What I've seen happen is sometimes, if I attempt to move a folder from one collection to another, and it says 'moved'. I will see that the folder now still exists in both collections. So what I had done is when I was done, I would delete the old collection. But doing so, appears to have deleted the sub folder from both old and new collections.

This does NOT happen for every one. And I can't reproduce it on command. So steps below are essentially what I've done, but it doesn't always happen.

This time, when I just realized what was happening, I had actually attempted to Move 3 Folders from first collection to 2nd. Popup claimed 3 folders were moved. But the Original collection still seemed to have a copy of one of those folders in it. What I noticed next was quite bizarre. I noticed that if I expanded the folder in collection1, it also expanded the duplicate in collection2. If I opened up a subfolder inside that folder, it also opened up the corresponding subfolder in collection2. It's like everything I did on one happened in the other. Almost like it was a virtual/linked copy. I also noticed that anything I deleted from one was removed from the other.

I tried closing and reopening Postman, I tried clearing the cache, nothing made the linked duplicate go away.

The only way I managed to work around this (for this folder), was to duplicate it, and move the duplicated folder to the new collection. Moving this duplicate did not have the same issue. (also the other 2 folders that I had originally attempted to move at the same time didn't have the issue).

So I don't know what it was about that particular folder... But now, I'm honestly afraid that I've accidentally managed to delete a bunch of my stuff that I had not meant to. And I think I need to restore from a full backup that I had taken and start my cleanup process again, and pay a bit more attention to this happening.

Steps To Reproduce

  1. Click on Folder1 inside Collection1
  2. Drag and drop into Collection2
  3. 'Toast' popup says: "1 folder has been moved"
  4. See that "Folder1" is now inside "Collection2"
  5. See that "Folder1" is also still inside "Collection1"
  6. Delete "Folder1" from "Collection1"
  7. Note that "Folder1" has been Deleted from both "Collection1" and "Collection2"

Screenshots or Videos

No response

Operating System

Windows 10

Postman Version

10.20.7

Postman Platform

Postman App

User Account Type

Signed In User

Additional Context?

Not sure I have anything more relevant at this point. If I get this to happen again, I'll try to capture some screenshots or video and add them.

cbecker-jwu commented 11 months ago

https://github.com/postmanlabs/postman-app-support/assets/11840531/1f48138a-594f-4fb8-a2b9-9b148f3f65c8

It just happened again. This is what it looks like once it's in that state.

Just as described before. 1) I created a folder inside the collection "Hold These To Place Later", called "Blackboard / ULearn" 2) I Clicked on the 4 folders inside The Collection "Blackboard / ULearn" and dragged them into the new folder. 3) Instead of moving the folders, it created this linked copy of them.