xbmc / xbmc

Kodi is an award-winning free and open source home theater/media center software and entertainment hub for digital media. With its beautiful interface and powerful skinning engine, it's available for Android, BSD, Linux, macOS, iOS, tvOS and Windows.
https://kodi.tv/
Other
18.48k stars 6.3k forks source link

Duplicate entries in TV Show library if episodes of same show are stored in different path-string font cases than the source path #25053

Open rafi-d opened 6 months ago

rafi-d commented 6 months ago

Bug report

Describe the bug

Here is a clear and concise description of what the problem is:

Duplicates entries of episodes in TV-Show episodes lists are created when source paths to the media-files are different in capitalized letters from the real path. Similar issue happens with the "Movies" library.

So a real path on Windows was: D:/path/Tv-show-name/ Kodi source path (on both android or Windows) was set to: smb://192.168.0.4/D/path/tv-show-name/

Above that: the media->library->clean function also does not remove such duplicates

Expected Behavior

Here is a clear and concise description of what was expected to happen:

Kodi should show a single entry on the TV-Shows -> episodes list

Actual Behavior

Kodi shows two entries - one for the real path and the other with the source path. Checked on 19.5, and 20.5.

Possible Fix

  1. Kodi should be able to match episodes' path names (at least on Windows) disregarding their capitalization. The OS might need to be specified for that.
  2. Kodi should provide a "browse" in the source path field to reduce the chance for such mistake, and make it easier to enter path names.
  3. Clean library function should remove such duplicates over smb: sources. It does notice the redundant / double entries path if the source is defined natively , on a local drive - without smb:, and suggests to delete the entries!

To Reproduce

Steps to reproduce the behavior:

  1. Create a show episode in smb://192.168.0.4/Path-name
  2. Set a source path to smb://192.168.0.4/path-name
  3. Define the source type as "tv-show and scan for new content

To recover:

  1. Rename the source to he exact path name
  2. Change the type of the source to None
  3. Change the type back to "TV-shows" and rescan
  4. DB will be partially cleared and re-created correctly
  5. If needed - rename the tv-show's folder, and clean the library, than rename back and re-scan.

Debuglog

The debuglog can be found here:

This has been reported long ago in both the forums and here (with a log): https://forum.kodi.tv/showthread.php?tid=218958&pid=3193778#pid3193778

17176

Screenshots

Here are some links or screenshots to help explain the problem:

Additional context or screenshots (if appropriate)

Here is some additional context or explanation that might help:

image

Your Environment

Used Operating system:

note: Once the issue is made we require you to update it with new information or Kodi versions should that be required. Team Kodi will consider your problem report however, we will not make any promises the problem will be solved.

rafi-d commented 6 months ago

One more piece of information: I am using the Watchdog addon on android to auto-add (and remove) new files to the library. I guess this is just trigger the issue more often.