Exception when generating cover (not the same MediaCover bug)

Hello,

Just started to use Sonarr and so far it’s a pretty amazing app!

I have just one small problem, I got several exceptions in the log about the cover generation. It’s almost like the MediaCover bug but I don’t think it’s the same as there is something weird about the mentioned path. It tries to look for a DLL with the full path to “/usr/local/lib”.

It installed on an ODROID-C1 (ARMv7) with Ubuntu 14 LTS and Mono 3.10 (dpkg from HTPC guide) and Sonarr 2.0.0.2837. I have libgdiplus installed from the official Ubuntu repo.

15-2-7 01:45:22.1|Fatal|GlobalExceptionHandlers|EPIC FAIL: An exception was thrown by the type initializer for System.Drawing.GDIPlus

System.TypeInitializationException: An exception was thrown by the type initializer for System.Drawing.GDIPlus ---> System.DllNotFoundException: /usr/local/lib
  at (wrapper managed-to-native) System.Drawing.GDIPlus:GdiplusStartup (ulong&,System.Drawing.GdiplusStartupInput&,System.Drawing.GdiplusStartupOutput&)
  at System.Drawing.GDIPlus..cctor () [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at System.Drawing.Image.InitFromStream (System.IO.Stream stream) [0x00000] in <filename unknown>:0 
  at System.Drawing.Bitmap..ctor (System.IO.Stream stream, Boolean useIcm) [0x00000] in <filename unknown>:0 
  at (wrapper remoting-invoke-with-check) System.Drawing.Bitmap:.ctor (System.IO.Stream,bool)
  at ImageResizer.ImageBuilder.DecodeStream (System.IO.Stream s, ImageResizer.ResizeSettings settings, System.String optionalPath) [0x00000] in <filename unknown>:0 
  at ImageResizer.ImageBuilder.LoadImage (System.Object source, ImageResizer.ResizeSettings settings, Boolean restoreStreamPos) [0x00000] in <filename unknown>:0 

15-2-7 01:45:22.1|Fatal|GlobalExceptionHandlers|EPIC FAIL: /usr/local/lib

System.DllNotFoundException: /usr/local/lib
  at (wrapper managed-to-native) System.Drawing.GDIPlus:GdiplusStartup (ulong&,System.Drawing.GdiplusStartupInput&,System.Drawing.GdiplusStartupOutput&)
  at System.Drawing.GDIPlus..cctor () [0x00000] in <filename unknown>:0

That does seem related, but might not be the same issue. We’re looking at changing how this feature was implemented since its not working as well as it should.

Thanks for letting us know, we’ll be looking into the overall issue in the coming days/weeks.

//cc @Taloth

Actually, due to some weird behavior in mono, we still end up with log entries. But that’s unrelated to it trying to load ‘/usr/local/lib’

The other problem is that your configuration has the wrong mapping for gdiplus.dll, could be a mono compilation error on your platform or just a config file somewhere. See here.
Pretty sure someone just screwed up a script somewhere.

Check ~/mono/data/config.in.

Thank you. There was indeed a wrong mapping in the config file. Fixed it manually and no more error.

FYI we also pushed an update that only logs the error on Debug level. So that’s another reason why you might not see it anymore.
Of course, if the posters on the UI actually are 250px in height, then it’s definitely working :smile: