Jump to content

Calculate statistics for all users failed - first error i encounter


KristofG

Recommended Posts

@Happy2Play I did the update to the plugin, restarted emby and the error is still happening. 

 

I'm in the process of refreshing the metadata on all my libraries, which is understandably taking a while, and while report back once that's done and I've had a chance to rerun the stats task. 

Link to comment
Share on other sites

The metadata refresh took a while but finished overnight. I tried the stats task the morning and it is still failing at the same point 88%. 

 

The debug logging shows it's dying at the same point it was before. 

I tried taking the file just before out of the folder (and refreshing the library) and it still fails. Which implies to me that it's the 'next file' or 'next step' that is failing out. 

Link to comment
Share on other sites

I noticed that the Statistics Plugin was updated again last night, this time 3.0.3.0
and gave it an install, restarted the emby server, and ran the task.  
Same error message, still at 88.0%
 

Object reference not set to an instance of an object.
at Statistics.Helpers.Calculator.CalculateMovieCodecs()
at Statistics.ScheduledTasks.CalculateStatsTask.MediaBrowser.Model.Tasks.IScheduledTask.Execute(CancellationToken cancellationToken, IProgress`1 progress)
at Emby.Server.Implementations.ScheduledTasks.ScheduledTaskWorker.ExecuteInternal(TaskOptions options)

 

I re-enabled DEBUG LOG, and ran it again, and a made a few observations

  • Still fails at the exact same point (see below)
  • it no longer shows the video quality (720p, 1080p, etc..) but now shows seemingly the codec? (h264, mpeg4, hevc)
  • it seems to only get about 67 episodes in before it fails out...

 

2022-09-07 08:23:57.390 Debug Statistics: CalculateMovieCodecs-episode Quantum Leap: 8 1/2 Months
2022-09-07 08:23:57.391 Debug Statistics: hevc
2022-09-07 08:23:57.391 Debug Statistics: CalculateMovieCodecs-episode Young Sheldon: 8-Bit Princess and a Flat Tire Genius
2022-09-07 08:23:57.391 Debug Statistics: h264
2022-09-07 08:23:57.391 Error TaskManager: Error
        *** Error Report ***
        Version: 4.8.0.8
        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: Linux version 5.15.0-47-generic (buildd@lcy02-amd64-060) (gcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0, GNU ld (GNU Binutils for Ubuntu) 2.38) #51-Ubuntu SMP
        Framework: .NET 6.0.8
        OS/Process: x64/x64
        Runtime: opt/emby-server/system/System.Private.CoreLib.dll
        Processor count: 4
        Data path: /var/lib/emby
        Application path: /opt/emby-server/system
        System.NullReferenceException: System.NullReferenceException: Object reference not set to an instance of an object.
           at Statistics.Helpers.Calculator.CalculateMovieCodecs()
           at Statistics.ScheduledTasks.CalculateStatsTask.MediaBrowser.Model.Tasks.IScheduledTask.Execute(CancellationToken cancellationToken, IProgress`1 progress)
           at Emby.Server.Implementations.ScheduledTasks.ScheduledTaskWorker.ExecuteInternal(TaskOptions options)
        Source: statistics
        TargetSite: statistics.Models.Configuration.ValueGroup CalculateMovieCodecs()

2022-09-07 08:23:57.392 Debug TaskManager: Calculate statistics for all users Failed after 0 minute(s) and 48 seconds
2022-09-07 08:23:57.396 Debug NotificationManager: Sending notification via Email Notifications to user <***AdminUser***>
2022-09-07 08:23:57.396 Info App: Sending email <***AdminEmail@domain.com***> with subject Emby: Calculate statistics for all users failed
2022-09-07 08:23:59.173 Info App: Completed sending email <***AdminEmail@domain.com***> with subject Emby: Calculate statistics for all users failed




 

Link to comment
Share on other sites

I noticed a new version of Statistics was releases (3.0.3.1), that indicates more logging.
I'm uploading an Anonymized Log that represents.  (only changes to the file were to scrub the admin id and the admin email address that are in the log)

  • Restart Emby Server
  • Enable DEBUG LOGging
  • running the statistics job
  • Restarting the Emby Server

embyserver-63798217786.txt

Link to comment
Share on other sites

Happy2Play
27 minutes ago, Karpana said:

I noticed a new version of Statistics was releases (3.0.3.1), that indicates more logging.
I'm uploading an Anonymized Log that represents.  (only changes to the file were to scrub the admin id and the admin email address that are in the log)

  • Restart Emby Server
  • Enable DEBUG LOGging
  • running the statistics job
  • Restarting the Emby Server

embyserver-63798217786.txt 1.1 MB · 1 download

Multiple topic discussing this where yours is still failing while this user has it working.

 

Link to comment
Share on other sites

I'll jump over then @Happy2Play

 

I've tried removing the media that's before/after the failure/error. 

 

I'm getting the distinct impression that the specific item that is failing isn't being correctly logged, so it feel like a needle in a haystack 

Link to comment
Share on other sites

Happy2Play

As discussed in the other topic the issue is Unidentified Series in Emby and Stats now choke on them.

Currently only fix is finding the offending Series/episodes, you have to copy the database and run this query to find the problem items.

as couple posts above in that link shows and example.

Link to comment
Share on other sites

  • 4 months later...
evanover

Been receiving this error for months when running Statistics. Error stated after update to 3.0.5.1

 

Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
at System.Collections.Generic.List`1.get_Item(Int32 index)
at Statistics.Helpers.Calculator.CalculateMostWatchedShows(UpdateModel tvdbData)
at Statistics.ScheduledTasks.CalculateStatsTask.MediaBrowser.Model.Tasks.IScheduledTask.Execute(CancellationToken cancellationToken, IProgress`1 progress)
at Emby.Server.Implementations.ScheduledTasks.ScheduledTaskWorker.ExecuteInternal(TaskOptions options)

embyserver-63809953373.txt embyserver.txt

Edited by evanover
Link to comment
Share on other sites

Lacika555
On 1/22/2023 at 10:44 PM, evanover said:

Been receiving this error for months when running Statistics. Error stated after update to 3.0.5.1

 

Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
at System.Collections.Generic.List`1.get_Item(Int32 index)
at Statistics.Helpers.Calculator.CalculateMostWatchedShows(UpdateModel tvdbData)
at Statistics.ScheduledTasks.CalculateStatsTask.MediaBrowser.Model.Tasks.IScheduledTask.Execute(CancellationToken cancellationToken, IProgress`1 progress)
at Emby.Server.Implementations.ScheduledTasks.ScheduledTaskWorker.ExecuteInternal(TaskOptions options)

embyserver-63809953373.txt 84.96 kB · 0 downloads embyserver.txt 1013.33 kB · 0 downloads

same here

It works with the older version, (3.0.4.0)  but unfortunately the current version is returned due to the auto update.

Edited by Lacika555
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...