Duplicate Tvshow Library Entries -- Almost Fixed!
#31
Jmarshall,

I just synced up and took a look at your changes. I actually thought about this exact scenario. Whether or not this is more efficient depends on the percentage of items that get stacked. If there are very few stackable items, the code is now less efficient as its unnecesarily resetting the show watched overlay and the fanart property.

The compromise would be to decleare a bool outside the inner loop and set it to true if the inner loop finds a match, and use that after the inner loop exits to change those properties if required. Something like this (pseudo-code):

Code:
while (i < size)
  get(i)
  j = i + 1
  bool bMatched = false
  while (j < size)
    get(j)
    if (i.title == j.title)
      bMatched = true
      update(i)
      remove(j)
    else break
  if (bMatched)
    update_more(i)
  i = j
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
Reply
#32
Multiple copies of the same episode aren't supported currently anyway, unless they're in a separate folder, and then the stacking stuff will make it work.

EDIT: kraqh3d: Sure, feel free to add the bool.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#33
done.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
Reply
#34
Time to dredge up this old thread for a question. I have some Series that are stored in 2 locations. The new/current Seasons are on a local drive where past seasons are stored on my NAS. This causes the show to be listed in the DB multiple times. Some are listed 3 times some only 2 times. The ones listed 3 times have one with the local path, one with the smb path, then one with a multipath. The ones listed twice only have the local path and smb path, no multipath.

Would it be possible for the DB to just have the multipath entry?

XBMC does only show one entry in Library mode, but that is not the case for the XBMC remote for iphone by Collect3. When using the app to browse my TV Library I see the multiple entries. Would the best course of action be to modify the XBMC remote code or to modify the DB code. At one point I know there was work on overhauling the whole DB, so maybe it is a moot point now.
Reply
#35
The remote should never have been accessing the database directly in the first place. That is the source of the problem here. Unfortunately direct queries to the database were allowed in the old HTTP-API, rather than a well-thought out API that didn't allow this sort of inconsistency.

Fortunately the JSON-RPC api is here to fix that.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#36
So how should it work then? Should the remote just send a query to XBMC and then display the results? I may use the wrong terminology since I am not programmer.
Reply
#37
Sorry to bump this thread, but I had a similar suggestion. I have episodes of tv shows on a nas, and I have plugin subscriptions for new episodes of those shows. This creates duplicate entries in the library. I know I can remove the plugin duplicates, but it re-adds every time it scans. Would it be possible to prevent the duplicates, or set a library preference(local sources first). This is mainly is an issue in psuedotv, but also affects launching a show from a remote in library mode.
Reply

Logout Mark Read Team Forum Stats Members Help
Duplicate Tvshow Library Entries -- Almost Fixed!0