Jump to content


Photo

Automatic version grouping for movies


  • Please log in to reply
34 replies to this topic

#1 MikePlanet OFFLINE  

MikePlanet

    Advanced Member

  • Alpha Testers
  • 353 posts
  • Local time: 06:02 PM

Posted 05 October 2018 - 04:34 AM

... as I was tired of manually grouping all my movie versions into groups after each recreation of the db, I created a plugin to help with that. 

The use case is having movies, that belong together spread around and not being able to easily match the emby naming conventions, but still having the desire to present them as one item with multiple versions.

The plugin works similar to the auto boxsets, but does the "movie versions grouping" - it will group all movies based on their TMDB id into one item, regardless of where they're placed and how they're named.

I made that for myself - however, if anybody is interested, attached is a plugin that solves this issue.

Attached version is for current 3.6.0.49 beta Server, do NOT use it with stable release!

Plugin is alpha state, you should only use it, if you are willing to backup your db (there is no way to revert the changes otherwise!) and manually put the dll in the server plugin directory.

Do not use it in your production environment before having tested in a test environment that you're fine with what it does - seriously! ;-).

Note: There is a known bug in the web GUI presentation which is described here, which needs to be fixed on emby side. 

 

Edit: the mentioned display bug in BoxSets is fixed in Emby now, thanks Luke.

Attached Files


Edited by MikePlanet, 07 July 2019 - 07:05 AM.

  • riffy, Baenwort, BarryAmerika and 4 others like this

#2 jaketame OFFLINE  

jaketame

    Advanced Member

  • Members
  • 187 posts
  • Local time: 06:02 PM

Posted 05 October 2018 - 04:42 AM

Mike,

Looks like a good plugin...

What do you need for testing results to move forward to make it more stable?
What versions of Beta are supported?
Can you apply the plugin to a specific library or does it affect all libraries?

Thanks!

#3 MikePlanet OFFLINE  

MikePlanet

    Advanced Member

  • Alpha Testers
  • 353 posts
  • Local time: 06:02 PM

Posted 05 October 2018 - 04:50 AM

regarding more stable: I use it regulary (means it is installed - it does all it's magic in the background) and it works for me - for me personally it is stable enough ;-)

versions: emby server version 3.6.0.49+ - as this one had breaking changes for the plugin. Former versions need an older version of the plugin.

Re specific library: no, it will do the grouping for all movies based on their tmdb-id, regardless of their location.

If you add a movie to your library, it will check, if the movie already exists and group it with the existin one(s) - if there is already a collection, it will add it.


Edited by MikePlanet, 05 October 2018 - 04:52 AM.


#4 jaketame OFFLINE  

jaketame

    Advanced Member

  • Members
  • 187 posts
  • Local time: 06:02 PM

Posted 05 October 2018 - 05:18 AM

Thats great thanks.

 

Where are logs incase of issues?

 

I'm running latest beta so no issues there.... I will install and report back.

 

Thanks



#5 MikePlanet OFFLINE  

MikePlanet

    Advanced Member

  • Alpha Testers
  • 353 posts
  • Local time: 06:02 PM

Posted 05 October 2018 - 07:26 AM

Where are logs incase of issues?

 

Log entries are written in the emby server log - as most plugins do



#6 jaketame OFFLINE  

jaketame

    Advanced Member

  • Members
  • 187 posts
  • Local time: 06:02 PM

Posted 05 October 2018 - 09:01 AM

Just deployed this and worked instantly :) Will test within app now.



#7 BarryAmerika OFFLINE  

BarryAmerika

    Advanced Member

  • Alpha Testers
  • 109 posts
  • Local time: 04:02 AM
  • LocationAustralia

Posted 20 December 2018 - 09:19 PM

I have installed this in Emby Version 3.6.0.76 beta - does anybody know if it still works with newer version? I can see the plugin but movies are not being grouped.



#8 MikePlanet OFFLINE  

MikePlanet

    Advanced Member

  • Alpha Testers
  • 353 posts
  • Local time: 06:02 PM

Posted 21 December 2018 - 07:54 AM

I have installed this in Emby Version 3.6.0.76 beta - does anybody know if it still works with newer version? I can see the plugin but movies are not being grouped.

 

It needs an update since beta 75, I uploaded a newer version to first post.


  • BarryAmerika likes this

#9 jaketame OFFLINE  

jaketame

    Advanced Member

  • Members
  • 187 posts
  • Local time: 06:02 PM

Posted 20 January 2019 - 09:24 AM

@Luke - Can we get something like this built in to span cross-directories for movies? Similar to TV Shows?



#10 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 138217 posts
  • Local time: 01:02 PM

Posted 20 January 2019 - 12:19 PM

It's possible for the future. thanks.



#11 raidz OFFLINE  

raidz

    Newbie

  • Members
  • 5 posts
  • Local time: 10:02 AM

Posted 03 May 2019 - 05:37 PM

Looks like this doesn't work in the newest version:

*** Error Report ***
	Version: 4.2.0.1
	Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_amd64.deb
	Operating system: Unix 4.20.10.6
	64-Bit OS: True
	64-Bit Process: True
	User Interactive: True
	Runtime: file:///opt/emby-server/system/System.Private.CoreLib.dll
	Processor count: 4
	Program data path: /var/lib/emby
	Application directory: /opt/emby-server/system
	System.MissingMethodException: System.MissingMethodException: Method not found: 'Int32 MediaBrowser.Controller.Entities.Video.get_MediaSourceCount()'.
	   at AutoCollections.Plugin.<>c.<UpdateCollection>b__24_0(Video i)
	   at System.Linq.Enumerable.TryGetFirst[TSource](IEnumerable`1 source, Func`2 predicate, Boolean& found)
	   at AutoCollections.Plugin.UpdateCollection(IGrouping`2 collection)
	   at AutoCollections.Plugin.CreateAllCollections(IProgress`1 progress, CancellationToken cancellationToken)
	Source: AutoCollections
	TargetSite: Boolean <UpdateCollection>b__24_0(MediaBrowser.Controller.Entities.Video)

Possible for you to fix this op?

 

Thanks!



#12 MikePlanet OFFLINE  

MikePlanet

    Advanced Member

  • Alpha Testers
  • 353 posts
  • Local time: 06:02 PM

Posted 05 May 2019 - 05:07 PM

Looks like this doesn't work in the newest version:

*** Error Report ***
	Version: 4.2.0.1
	Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_amd64.deb
	Operating system: Unix 4.20.10.6
	64-Bit OS: True
	64-Bit Process: True
	User Interactive: True
	Runtime: file:///opt/emby-server/system/System.Private.CoreLib.dll
	Processor count: 4
	Program data path: /var/lib/emby
	Application directory: /opt/emby-server/system
	System.MissingMethodException: System.MissingMethodException: Method not found: 'Int32 MediaBrowser.Controller.Entities.Video.get_MediaSourceCount()'.
	   at AutoCollections.Plugin.<>c.<UpdateCollection>b__24_0(Video i)
	   at System.Linq.Enumerable.TryGetFirst[TSource](IEnumerable`1 source, Func`2 predicate, Boolean& found)
	   at AutoCollections.Plugin.UpdateCollection(IGrouping`2 collection)
	   at AutoCollections.Plugin.CreateAllCollections(IProgress`1 progress, CancellationToken cancellationToken)
	Source: AutoCollections
	TargetSite: Boolean <UpdateCollection>b__24_0(MediaBrowser.Controller.Entities.Video)

Possible for you to fix this op?

 

Thanks!

I have attached an updated version to the first post, that I use with current 4.3.0.1 Server.


Edited by MikePlanet, 07 July 2019 - 07:10 AM.

  • raidz likes this

#13 raidz OFFLINE  

raidz

    Newbie

  • Members
  • 5 posts
  • Local time: 10:02 AM

Posted 06 May 2019 - 10:59 AM

I have attached an updated version to the first post, that I use with current 4.3.0.1 Server.

 

Thank you, much appreciated!



#14 rapteev OFFLINE  

rapteev

    Advanced Member

  • Members
  • 58 posts
  • Local time: 06:02 PM

Posted 14 May 2019 - 05:16 AM

Hi
Just want to thank you.
Great plugin.

#15 jaketame OFFLINE  

jaketame

    Advanced Member

  • Members
  • 187 posts
  • Local time: 06:02 PM

Posted 21 June 2019 - 03:24 PM

Hey Mike - Did you have the latest .dll available? The one in the first posted mark 4.1.0.15 doesn't work with Beta 4.2.0.18

2019-06-21 20:23:36.191 Error App: Error sending web socket message Sessions
*** Error Report ***
Version: 4.2.0.18
Command line: /system/EmbyServer.dll -programdata /config -ffdetect /bin/ffdetect -ffmpeg /bin/ffmpeg -ffprobe /bin/ffprobe -restartexitcode 3
Operating system: Unix 4.18.0.21
64-Bit OS: True
64-Bit Process: True
User Interactive: True
Runtime: file:///system/System.Private.CoreLib.dll
Processor count: 8
Program data path: /config
Application directory: /system
System.ObjectDisposedException: System.ObjectDisposedException: The CancellationTokenSource has been disposed.
   at System.Threading.CancellationTokenSource.ThrowObjectDisposedException()
   at System.Threading.CancellationTokenSource.get_Token()
   at MediaBrowser.Controller.Net.BasePeriodicWebSocketListener`2.SendData(Tuple`3 tuple)
Source: System.Private.CoreLib
TargetSite: Void ThrowObjectDisposedException()

Edited by jaketame, 21 June 2019 - 03:25 PM.


#16 jhalttu OFFLINE  

jhalttu

    Newbie

  • Members
  • 6 posts
  • Local time: 08:02 PM

Posted 22 June 2019 - 04:29 PM

Hi... Where Do I put this DLL on my QNAP?



#17 Happy2Play OFFLINE  

Happy2Play

    Trial and Error

  • Moderators
  • 15760 posts
  • Local time: 10:02 AM
  • LocationWashington State

Posted 22 June 2019 - 04:41 PM

Hi... Where Do I put this DLL on my QNAP?

 
Your log will tell you near the top.
 
From logs found in QNAP section

Program data path: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata



/share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata/plugins

Edited by Happy2Play, 22 June 2019 - 04:41 PM.


#18 jhalttu OFFLINE  

jhalttu

    Newbie

  • Members
  • 6 posts
  • Local time: 08:02 PM

Posted 22 June 2019 - 04:50 PM

yeah... then I have to learn how to use putty/ftp, ie.. hehe. 



#19 jhalttu OFFLINE  

jhalttu

    Newbie

  • Members
  • 6 posts
  • Local time: 08:02 PM

Posted 22 June 2019 - 05:14 PM

I was not hard..

Just installed Putty

And used this command:

 

addshare EMBY "/share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata" -uw:admin

 

Then went to fileshare on Qnap and found new created EMBY folder.. Uploaded that .DLL ínside EMBY/Plug-ins/ folder..

REstarted EMBY...

 

IT works... I got rid of all copies of films and they are found under film as different versions

 

  5d0e9a337a6d7_Sieppaa.png


Edited by jhalttu, 22 June 2019 - 05:15 PM.

  • MikePlanet likes this

#20 MikePlanet OFFLINE  

MikePlanet

    Advanced Member

  • Alpha Testers
  • 353 posts
  • Local time: 06:02 PM

Posted 07 July 2019 - 04:30 PM

 

Hey Mike - Did you have the latest .dll available? The one in the first posted mark 4.1.0.15 doesn't work with Beta 4.2.0.18

2019-06-21 20:23:36.191 Error App: Error sending web socket message Sessions
*** Error Report ***
Version: 4.2.0.18
Command line: /system/EmbyServer.dll -programdata /config -ffdetect /bin/ffdetect -ffmpeg /bin/ffmpeg -ffprobe /bin/ffprobe -restartexitcode 3
Operating system: Unix 4.18.0.21
64-Bit OS: True
64-Bit Process: True
User Interactive: True
Runtime: file:///system/System.Private.CoreLib.dll
Processor count: 8
Program data path: /config
Application directory: /system
System.ObjectDisposedException: System.ObjectDisposedException: The CancellationTokenSource has been disposed.
   at System.Threading.CancellationTokenSource.ThrowObjectDisposedException()
   at System.Threading.CancellationTokenSource.get_Token()
   at MediaBrowser.Controller.Net.BasePeriodicWebSocketListener`2.SendData(Tuple`3 tuple)
Source: System.Private.CoreLib
TargetSite: Void ThrowObjectDisposedException()

... I don't think the exception is related to the plugin; however, I updated the first post with a version that is compatible with current beta server.


Edited by MikePlanet, 07 July 2019 - 04:30 PM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users