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

[BUG] "Fix Unlinked Entries"/"Refresh Directories" Creates Duplicate Entries for Moved Files #179

Closed
CyanVoxel opened this issue May 15, 2024 · 0 comments
Labels
TagStudio: Library Relating to the TagStudio library system Type: Bug Something isn't working as intended
Milestone

Comments

@CyanVoxel
Copy link
Member

TagStudio Version

Alpha v9.2.0

Operating System

Windows 10 22H2

Describe The Issue

The "Fixed Unlinked Entries" does not take into account entries for existing files when relinking entries, thus creating duplicate entries for the same files.

Steps to Reproduce

  1. Create a library full of files
  2. Move those files into a subfolder (this breaks the links)
  3. Refresh the library directories (this creates new entries for the files while not touching the old unlinked ones)
  4. Use the "Fix Unlinked Entries" option. The old entries are now relinked, but without reconciling the duplicate entries that were created in the meantime
    image
@CyanVoxel CyanVoxel added the Type: Bug Something isn't working as intended label May 15, 2024
@CyanVoxel CyanVoxel added this to the Alpha 9.2.1 milestone May 15, 2024
@CyanVoxel CyanVoxel added the TagStudio: Library Relating to the TagStudio library system label May 15, 2024
CyanVoxel added a commit that referenced this issue May 21, 2024
CyanVoxel added a commit that referenced this issue May 21, 2024
CyanVoxel added a commit that referenced this issue May 29, 2024
* Reapply "Add duplicate entry handling (Fix #179)"

This reverts commit 66ec091.

* Reapply "Fix create library + type checks"

This reverts commit 57e27bb.

* Type and hint changes

* Remove object cast

* MyPy wrestling

* Remove type: ignore, change __eq__ cast

- Remove `type: ignore` comments from `Entry`'s `__eq__` method
- Change the cast in this method from `__value = cast(Self, object)` to `__value = cast(Self, __value)`

Co-Authored-By: Jiri <yedpodtrzitko@users.noreply.github.com>

* Fix formatting + mypy

---------

Co-authored-by: Jiri <yedpodtrzitko@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TagStudio: Library Relating to the TagStudio library system Type: Bug Something isn't working as intended
Projects
None yet
Development

No branches or pull requests

1 participant