Jump to content

Developing a standalone embystat server


reggi

Recommended Posts

jaycedk

tbh if I just came across something. I would stop and see what was going on ^^.

Guess in this case, I would read about it, before asking.......

Or at least read into it.

You do not know what might be hidding in your docker/container ;)

So make sure you get the right version, and not an clone, that has been edited.

Edited by jaycedk
Link to comment
Share on other sites

  • 2 weeks later...

hi, i just download this docker on my unraid server, using the last stable emby server

 

on my embystat dashboard all i see is No content here yet (string is not translated either) , is that normal?

 

here are the logs if is need it

 

thanks in advanced

 

 

 

Edited by mata7
Link to comment
Share on other sites

Happy2Play

hi, i just download this docker on my unraid server, using the last stable emby server

 

on my embystat dashboard all i see is No content here yet (string is not translated either) , is that normal?

 

here are the logs if is need it

 

thanks in advanced

 

Same question asked in post 574.

 

Yes this is currently the expected result.

Link to comment
Share on other sites

Hey guys, I released beta.13 yesterday. I did made a mistake with the build so if your updates fails remove the "updateFiles" folder and *.ver file in the root folder and try to update the application again.

 

It took a while for this update because I had to test a lot but I did decrease the RAM usage from 2Gb to 300Mb after a media sync, so that's goind on the good direction I guess. Still some more work to do!

 

Changes:

Fixed issue with multiple special seasons #949
Fixed issue with duplicate seasons #950
Fixed unallocated memory #927, #971
Fixed wrong movie count in logs #973
Added SonarQube scan
Added linux-arm package
Added 200 backend unit tests
 
I also fixed some small bugs found when I was creating the unit tests :) As of this moment I have a coverage of 35% (frontend code included) so I will have to increase that over time as well.
Going to start implementing new features for the next release!
 
Happy testing and thanks for the patience! 
  • Like 2
Link to comment
Share on other sites

mgworek

I updated this morning. My Media Sync fails but it looks like it failed before the update as well. Sorry for not reporting it sooner. It's been awhile since I looked at it.

 

Media synchronisation

Last run a moment ago, but failed after 12 second(s) 
 

 

Log file attached.

 

I just deleted it and starting from scratch since I do not know how long it has been failing for. Looks like it is working now. Before it got through my Movies but failed on my Cartoons.

2019-11-13.log

Edited by mgworek
Link to comment
Share on other sites

Diedrich

Big problems with v.13. I can't get past the wizard login. The popup notification says my user isn't an admin, which it is. Problem #2, I can't download the anonymized log, I get a json error.

"{\"Message\":\"An unhandled error occurred.\",\"IsError\":false,\"Detail\":null,\"Stack\":null}"

I'm PM'ing you my full log.

  • Like 1
Link to comment
Share on other sites

That "Unable to cast object of type 'LiteDB.EmptyPage' to type 'LiteDB.HeaderPage'" error is something nasty from liteDB. I have to look into it a bit more to see how I can fix that one.

Their V5 is in beta so let's hope when it releases I can update and the error will be gone.

 

As for the problem with the wizard, I'm preparing a PR at the moment. So that should be fixed soon!

  • Like 2
Link to comment
Share on other sites

@@anthonws, since the stack trace mentions the "Statistics" namespace I presume this is an Emby Statistics plugin error and not an error from EmbyStat.

I'll see if I can create a quick fix for the issue or just remove the failing statistic for now since later this week.

  • Like 1
Link to comment
Share on other sites

anthonws

@@anthonws, since the stack trace mentions the "Statistics" namespace I presume this is an Emby Statistics plugin error and not an error from EmbyStat.

I'll see if I can create a quick fix for the issue or just remove the failing statistic for now since later this week.

Apologies @@reggi! I don't know why, I've completely confused "Statistics" and the "EmbyStat" project... I'll install EmbyStat asap :)

Link to comment
Share on other sites

rdmiller13
Is this more or related to the tvdb issue?  Only get's through 113 series before it kicks this back.  It was at 114, but I removed that series and it just seems to back up one, but same value name.  With the exception of misreading season 3 on one show and misreading another show altogether, it works fine within the shows tab.

 

 

 

2019-11-22 22:42:14.7556 [ERROR] Error while running job LiteDB.LiteException: Cannot insert duplicate key in unique index '_id'. The duplicate value is '152877'.

   at LiteDB.IndexService.AddNode(CollectionIndex index, BsonValue key, Byte level, IndexNode last)

   at LiteDB.IndexService.AddNode(CollectionIndex index, BsonValue key, IndexNode last)

   at LiteDB.LiteEngine.InsertDocument(CollectionPage col, BsonDocument doc, BsonType autoId)

   at LiteDB.LiteEngine.<>c__DisplayClass22_0.<Insert>b__0(CollectionPage col)

   at LiteDB.LiteEngine.Transaction[T](String collection, Boolean addIfNotExists, Func`2 action)

   at LiteDB.LiteEngine.InsertBulk(String collection, IEnumerable`1 docs, Int32 batchSize, BsonType autoId)

   at LiteDB.LiteCollection`1.InsertBulk(IEnumerable`1 docs, Int32 batchSize)

   at EmbyStat.Repositories.ShowRepository.<>c__DisplayClass5_0.<UpsertShow>b__0() in d:\a\1\s\EmbyStat.Repositories\ShowRepository.cs:line 90

   at EmbyStat.Repositories.BaseRepository.ExecuteQuery(Action query) in d:\a\1\s\EmbyStat.Repositories\BaseRepository.cs:line 29

   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.PerformShowSyncAsync(IReadOnlyList`1 showsThatNeedAnUpdate, Library library, DateTime updateStartTime) in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 267

   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.ProcessShowsAsync(IEnumerable`1 libraries, CancellationToken cancellationToken) in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 204

   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.RunJobAsync() in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 85

   at EmbyStat.Jobs.BaseJob.Execute() in d:\a\1\s\EmbyStat.Jobs\BaseJob.cs:line 54

2019-11-22 22:42:14.7771 [ERROR] MEDIASYNC-JOB Job failed, check logs for more info. 

  • Like 3
Link to comment
Share on other sites

psybertech

Hey @@reggi... love the concept so I just tried to install on Ubuntu server 16.04 VM... all was well until the initial sync but ran into errors.

 

I stopped, apt-get updated/upgraded and then rebooted and tried again, but still can't get it to sync.

 

Attached are the logs...

 

Thanks for all your work! :)

 

2019-11-22.log

Link to comment
Share on other sites

  • 2 weeks later...

Hey @@psybertech, sorry I missed your message! I'll have a look for the next release because I just released beta.14. 

 

Just a small increment that moves from user login to API key authentication.

I also implemented frontend unit tests but as a user you don't see that. Currently on a coverage of 43,5% (I'm getting there :) )

  • Like 2
Link to comment
Share on other sites

Thanks man!

 

It's going way slower that I ever imagined but it's a very steep learning curve for me as well :)

Link to comment
Share on other sites

rdmiller13
2019-12-03 17:17:22.1155 [ERROR] Error while running job LiteDB.LiteException: Cannot insert duplicate key in unique index '_id'. The duplicate value is '152877'.

   at LiteDB.IndexService.AddNode(CollectionIndex index, BsonValue key, Byte level, IndexNode last)

   at LiteDB.IndexService.AddNode(CollectionIndex index, BsonValue key, IndexNode last)

   at LiteDB.LiteEngine.InsertDocument(CollectionPage col, BsonDocument doc, BsonType autoId)

   at LiteDB.LiteEngine.<>c__DisplayClass22_0.<Insert>b__0(CollectionPage col)

   at LiteDB.LiteEngine.Transaction[T](String collection, Boolean addIfNotExists, Func`2 action)

   at LiteDB.LiteEngine.InsertBulk(String collection, IEnumerable`1 docs, Int32 batchSize, BsonType autoId)

   at LiteDB.LiteCollection`1.InsertBulk(IEnumerable`1 docs, Int32 batchSize)

   at EmbyStat.Repositories.ShowRepository.<>c__DisplayClass5_0.<UpsertShow>b__0() in d:\a\1\s\EmbyStat.Repositories\ShowRepository.cs:line 90

   at EmbyStat.Repositories.BaseRepository.ExecuteQuery(Action query) in d:\a\1\s\EmbyStat.Repositories\BaseRepository.cs:line 29

   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.PerformShowSyncAsync(IReadOnlyList`1 showsThatNeedAnUpdate, Library library, DateTime updateStartTime) in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 264

   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.ProcessShowsAsync(IEnumerable`1 libraries, CancellationToken cancellationToken) in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 202

   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.RunJobAsync() in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 85

   at EmbyStat.Jobs.BaseJob.Execute() in d:\a\1\s\EmbyStat.Jobs\BaseJob.cs:line 54

2019-12-03 17:17:22.2750 [ERROR] MEDIASYNC-JOB Job failed, check logs for more info. 

2019-12-03 17:17:23.9623 [WARN] Failed to process the job 'ee7161dc-333c-48dd-a7f6-2b44d65666b5': an exception occurred. Retry attempt 2 of 2 will be performed in 00:00:18. LiteDB.LiteException: Cannot insert duplicate key in unique index '_id'. The duplicate value is '152877'.

 

Any thoughts on this by chance?  On release 14 - same error it looks like - still not sure it's not something on my end or just something still residual issues from tvdb :(

 

Thanks for any info though!

Link to comment
Share on other sites

StevenDTX

 

2019-12-03 17:17:22.1155 [ERROR] Error while running job LiteDB.LiteException: Cannot insert duplicate key in unique index '_id'. The duplicate value is '152877'.
   at LiteDB.IndexService.AddNode(CollectionIndex index, BsonValue key, Byte level, IndexNode last)
   at LiteDB.IndexService.AddNode(CollectionIndex index, BsonValue key, IndexNode last)
   at LiteDB.LiteEngine.InsertDocument(CollectionPage col, BsonDocument doc, BsonType autoId)
   at LiteDB.LiteEngine.<>c__DisplayClass22_0.<Insert>b__0(CollectionPage col)
   at LiteDB.LiteEngine.Transaction[T](String collection, Boolean addIfNotExists, Func`2 action)
   at LiteDB.LiteEngine.InsertBulk(String collection, IEnumerable`1 docs, Int32 batchSize, BsonType autoId)
   at LiteDB.LiteCollection`1.InsertBulk(IEnumerable`1 docs, Int32 batchSize)
   at EmbyStat.Repositories.ShowRepository.<>c__DisplayClass5_0.<UpsertShow>b__0() in d:\a\1\s\EmbyStat.Repositories\ShowRepository.cs:line 90
   at EmbyStat.Repositories.BaseRepository.ExecuteQuery(Action query) in d:\a\1\s\EmbyStat.Repositories\BaseRepository.cs:line 29
   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.PerformShowSyncAsync(IReadOnlyList`1 showsThatNeedAnUpdate, Library library, DateTime updateStartTime) in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 264
   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.ProcessShowsAsync(IEnumerable`1 libraries, CancellationToken cancellationToken) in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 202
   at EmbyStat.Jobs.Jobs.Sync.MediaSyncJob.RunJobAsync() in d:\a\1\s\EmbyStat.Jobs\Jobs\Sync\MediaSyncJob.cs:line 85
   at EmbyStat.Jobs.BaseJob.Execute() in d:\a\1\s\EmbyStat.Jobs\BaseJob.cs:line 54
2019-12-03 17:17:22.2750 [ERROR] MEDIASYNC-JOB Job failed, check logs for more info. 
2019-12-03 17:17:23.9623 [WARN] Failed to process the job 'ee7161dc-333c-48dd-a7f6-2b44d65666b5': an exception occurred. Retry attempt 2 of 2 will be performed in 00:00:18. LiteDB.LiteException: Cannot insert duplicate key in unique index '_id'. The duplicate value is '152877'.
 
Any thoughts on this by chance?  On release 14 - same error it looks like - still not sure it's not something on my end or just something still residual issues from tvdb :(
 
Thanks for any info though!

 

 

I'm seeing the same issue on v13 and v14.  My initial Media sync job never completes.

Edited by StevenDTX
Link to comment
Share on other sites

psybertech

I just installed the latest and see that above error (different ID of course) too.

But, without looking into what show that ID was pointing to, I was thinking that it was due to me having some shows in two libraries (i.e. kids tv cartoons library and my all tv library which includes cartoons too).

I'll dive in to see on my end later, but with the new update I no longer ran into my "The given key '##' was not present in the dictionary."   :D @@reggi

At least I see it scanning and making headway until the dupe _id exceptions now.

 

I'll post if my thought is correct with it being a dupe of a second instance in another library (which I know is probably frowned upon overall).

 

 

j

Link to comment
Share on other sites

rdmiller13

It was on show 113 or 114...I've since added more, now it's show 118...but the same show...but if remove it, it just goes to the next one.  If I remove that one, same thing.

 

All my TV Shows are only in one subfolder so I know it's not duplicating it...UNLESS, where I think tvdb...they have something screwy maybe from their migration?

Link to comment
Share on other sites

Seems indeed like there are shows in more then one library, but @@rdmiller13 mentioned he doesn't have any duplicate libraries.

Someone else posted this issue on github as well and I created a test version for it posted here: https://github.com/mregni/EmbyStat/issues/1007#issuecomment-561301424

 

Feel free to test it out and report back to me if this version fixed your problem. Be aware, this is a Windows x64 build only.

Link to comment
Share on other sites

rdmiller13

@reggi - looks great - I remoted in back home and grabbed it and it's still running...processed all 324 shows and 2300ish movies...still processing, but it definitely got to everything...one show had an error, but that's probably on my side - will check out the logs later when it finishes and I get home.

  • Like 1
Link to comment
Share on other sites

@@rdmiller13, thanks for the feedback! 

Is seems there is still a bug when an episode has no season (for some strange reason) so it could be possible that the fails in the end while calculating the show statistics. If so, you can always PM me your log.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...