Skip to main content
Topic: Biography Discussion (Read 77518 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Re: Biography Discussion

Reply #450
@WilB :
Hello WilB, the script with the debug code is now running. I will update you asap. Thanks a lot for your support.

Attached the screenshots of the cached images with details of their sizes.
I provide you also compy of my current INI file in case it should have some wrong settings: I limited a lot the cache size...

Kind regards, Andrea

Re: Biography Discussion

Reply #451
@WilB:
Hello WilB, today I having continous crashes every few tens of seconds.

Privately I sent to you the full console log.

Here attached only the most relevant screenshots.

Kind regards,
Andrea

Re: Biography Discussion

Reply #452
Looking at the debug report the error is occurring on image.Resize() as before. The report also shows that the image existed, had valid dimensions (3141 x 4396) and that the target resize (271 x 379) was as expected. At ~3.5 MB the image isn't especially large and memory usage immediately before the resize event was very low (47.7 MB). As far as I can see this error is outside my control, since the image.Resize() event is handled by Spider Monkey Panel. May be @TheQwertiest can help? I also have that image on my device saved at exactly the same size & here biography loads it without issue. The full debug report is below.
 
Code: [Select]
 image EXIST true  
 image.Width 3141 
 image.Height 4396 
 img.crop false 
 circular false 
 imgx 0 imgy 0 imgw 100 imgh 100 
 image_path C:\Users\PersonalInfoRemoved\AppData\Roaming\foobar2000\yttm\art_img\p\Pink
 Floyd\Pink Floyd_9634c23d999a4ee7a14107577156f990.jpg 
 image file EXIST true 
 image file SIZE 3460022 
 this.cache_.img EXIST true 
 this.cache_.img.Width 3141 
 this.cache_.img.Height 4396 
 Resize width tw 271 Resize height th 379 
 SMP memory usage: window.TotalMemoryUsage: 47.75434 MB 
 Error: Spider Monkey Panel v1.2.2-preview+0db3c6a4 (Biography v1.1.2 beta1
 with debug code by WilB) 
 Resize failed: 
 GdiPlus error: DrawImage failed with error (0x3): OutOfMemory 

 File:  
 Line: 3283, Column: 26 

 Stack trace: 
 ImageCache/this.cacheIt@:3283:26 
 Images/this.load_image_done@:2933:5 
 on_load_image_done@:3467:53 
 Error: Spider Monkey Panel v1.2.2-preview+0db3c6a4 (Biography v1.1.2 beta1
 with debug code by WilB) 
 Resize failed: 
 GdiPlus error: DrawImage failed with error (0x3): OutOfMemory 

 File:  
 Line: 3283, Column: 26 

 Stack trace: 
 ImageCache/this.cacheIt@:3283:26 
 Images/this.load_image_done@:2933:5 
 on_load_image_done@:3467:53


Re: Biography Discussion

Reply #454
Cache only retains images for the current artist, adding images individually on load. Once the artist changes the cache is flushed, so there should never be that many.  That's also indicated by the memory consumption of only 47.7 MB, just prior to the resize error. Cache is also flushed if the images need to be displayed at a different size etc.

@AndreaT To get the number in the cache, put the following snippet somewhere amongst the debug code:
Code: [Select]
console.log("this.cache.length",this.cache.length);

Edit: Looking at the more extended debug log that I have, it appears that the error occurred as it tried to load the fourth image into the cache.


Re: Biography Discussion

Reply #456
@WilB: OK, I will do, however, kindly consider that in my INI file I limited that number to 5.
I will update you as soon as I will get a new crash log.
Thanks and regards, Andrea

 

Re: Biography Discussion

Reply #458
Debug code will tell you which image it errored on: it will be the last one in the console output, i.e. the one above the error (debug code shows the image_path).

INI setting is OK; updates to the images for a particular artist occur every 28 days and so your frequent error is unrelated. Also no attempt to delete excess images for a particular artist is made until a different artist is played. I just retested anyway to confirm (with Pink Floyd). You could always temporarily reset INI to default settings...

Re: Biography Discussion

Reply #459
@WilB and @TheQwertiest :
Hello, here a new crash with cache size log.

Biography Server: allmusic album review: From The Vault - Extended Play Edition / Pink Floyd: not found
Biography Server: allmusic album review: Defacing The Wall / Pink Floyd: not found
Biography Server: allmusic album review: The Great Gig In The Sky / Pink Floyd: not found
Biography Server: allmusic album review: Greatest Hits / Pink Floyd: not found
image EXIST true
image.Width 500
image.Height 500
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path stub4
image file EXIST false
this.cache.img EXIST true
this.cache.img.Width 500
this.cache.img.Height 500
this.cache.length 1
Resize width tw 578 Resize height th 578
SMP memory usage: window.TotalMemoryUsage: 9.513484 MB
image EXIST true
image.Width 500
image.Height 500
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path stub4
image file EXIST false
this.cache.img EXIST true
this.cache.img.Width 500
this.cache.img.Height 500
this.cache.length 1
Resize width tw 578 Resize height th 578
SMP memory usage: window.TotalMemoryUsage: 9.513484 MB
image EXIST true
image.Width 500
image.Height 500
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path stub4
image file EXIST false
this.cache.img EXIST true
this.cache.img.Width 500
this.cache.img.Height 500
this.cache.length 1
Resize width tw 578 Resize height th 578
SMP memory usage: window.TotalMemoryUsage: 9.513484 MB
image EXIST true
image.Width 500
image.Height 500
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path stub4
image file EXIST false
this.cache.img EXIST true
this.cache.img.Width 500
this.cache.img.Height 500
this.cache.length 1
Resize width tw 578 Resize height th 578
SMP memory usage: window.TotalMemoryUsage: 9.513484 MB
image EXIST true
image.Width 774
image.Height 706
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path C:\Users\AdmAT\AppData\Roaming\foobar2000\yttm\art_img\p\Pink Floyd\Pink Floyd_7dd43e535e5a490a811199ff902811e6.jpg
image file EXIST true
image file SIZE 893302
this.cache.img EXIST true
this.cache.img.Width 774
this.cache.img.Height 706
this.cache.length 1
Resize width tw 416 Resize height th 379
SMP memory usage: window.TotalMemoryUsage: 9.513484 MB
Biography Server: allmusic album review: Proper Education / Eric Prydz vs Floyd: not found
Biography Server: allmusic biography: Eric Prydz vs Floyd: not found
Biography Server: allmusic album review: A Tree Full Of Secrets (1) / Pink Floyd: not found
Biography Server: last.fm album review: A Tree Full Of Secrets (1) / Pink Floyd: not found Status error: 404
image EXIST true
image.Width 1280
image.Height 855
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path C:\Users\AdmAT\AppData\Roaming\foobar2000\yttm\art_img\p\Pink Floyd\Pink Floyd_05b95f02395f4f038129a9cc2c3e6a6b.jpg
image file EXIST true
image file SIZE 1611201
this.cache.img EXIST true
this.cache.img.Width 1280
this.cache.img.Height 855
this.cache.length 2
Resize width tw 567 Resize height th 379
SMP memory usage: window.TotalMemoryUsage: 6.663612 MB
Opening track for playback: "H:\Pink Floyd\2012 - Defacing The Wall\01. Pink Floyd - Another Brick In The Wall II (Extended).flac"
image EXIST true
image.Width 3141
image.Height 4396
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path C:\Users\AdmAT\AppData\Roaming\foobar2000\yttm\art_img\p\Pink Floyd\Pink Floyd_9634c23d999a4ee7a14107577156f990.jpg
image file EXIST true
image file SIZE 3460022
this.cache.img EXIST true
this.cache.img.Width 3141
this.cache.img.Height 4396
this.cache.length 3
Resize width tw 271 Resize height th 379
SMP memory usage: window.TotalMemoryUsage: 7.50036 MB
Error: Spider Monkey Panel v1.2.2-preview+0db3c6a4 (Biography v1.1.2 beta1 with debug code2 by WilB)
Resize failed:
GdiPlus error: DrawImage failed with error (0x7): Win32Error

File: <main>
Line: 3284, Column: 26

Stack trace:
  ImageCache/this.cacheIt@<main>:3284:26
  Images/this.load_image_done@<main>:2933:5
  on_load_image_done@<main>:3468:53
Error: Spider Monkey Panel v1.2.2-preview+0db3c6a4 (Biography v1.1.2 beta1 with debug code2 by WilB)
Resize failed:
GdiPlus error: DrawImage failed with error (0x7): Win32Error

File: <main>
Line: 3284, Column: 26

Stack trace:
  ImageCache/this.cacheIt@<main>:3284:26
  Images/this.load_image_done@<main>:2933:5
  on_load_image_done@<main>:3468:53

Regards, Andrea

Re: Biography Discussion

Reply #460
@TheQwertiest and @WilB :
Hello great Developers!
I would just share with you the good news that since TheQwerties gave me SMP ver 1.2.3-test and 1.2.3-beta, Biography JS is running smooth.
Since then I did not have any error.
Thanks and kind regards, Andrea


Re: Biography Discussion

Reply #462
@TheQwertiest and @WilB

Hello TheQwertiest and WilB,
I do not know if just a case of something more, but today I had new crashes of the Biography JS.

I installed the new SMP 1.2.3-beta (version I got today) and as I played the Pink Floyd I got the error:

From the splash window:
Error: Spider Monkey Panel v1.2.3-beta+31f7ed0a (Biography v1.1.2 beta1 with debug code2 by WilB)
Resize failed:
GdiPlus error: DrawImage failed with error (0x3): OutOfMemory

File: <main>
Line: 3284, Column: 26

Stack trace:
  ImageCache/this.cacheIt@<main>:3284:26
  Images/this.load_image_done@<main>:2933:5
  on_load_image_done@<main>:3468:53


And from the cosole.log:
Opening track for playback: "I:\Pink Floyd\2014 - The Endless River (SACD ISO)\Pink Floyd - The Endless River (2014).ISO"
image EXIST true
image.Width 600
image.Height 600
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path C:\Users\AdmAT\AppData\Roaming\foobar2000\yttm\art_img\p\Pink Floyd\Pink Floyd_e7090eb6d05349ae8e0932264910d875.jpg
image file EXIST true
image file SIZE 717500
this.cache.img EXIST true
this.cache.img.Width 600
this.cache.img.Height 600
this.cache.length 1
Resize width tw 377 Resize height th 377
SMP memory usage: window.TotalMemoryUsage: 8.106236 MB
image EXIST true
image.Width 3141
image.Height 4396
img.crop false
circular false
imgx 0 imgy 0 imgw 100 imgh 100
image_path C:\Users\AdmAT\AppData\Roaming\foobar2000\yttm\art_img\p\Pink Floyd\Pink Floyd_9634c23d999a4ee7a14107577156f990.jpg
image file EXIST true
image file SIZE 3460022
this.cache.img EXIST true
this.cache.img.Width 3141
this.cache.img.Height 4396
this.cache.length 2
Resize width tw 269 Resize height th 377
SMP memory usage: window.TotalMemoryUsage: 8.106236 MB
Error: Spider Monkey Panel v1.2.3-beta+31f7ed0a (Biography v1.1.2 beta1 with debug code2 by WilB)
Resize failed:
GdiPlus error: DrawImage failed with error (0x3): OutOfMemory

File: <main>
Line: 3284, Column: 26

Stack trace:
  ImageCache/this.cacheIt@<main>:3284:26
  Images/this.load_image_done@<main>:2933:5
  on_load_image_done@<main>:3468:53


Kind regards, Andrea

Re: Biography Discussion

Reply #463
I also had a possibly similar report from another user with an image.ApplyMask error (ApplyMask failed:  GdiPlus error: dst::LockBits failed with error (0x3): OutOfMemory: Spider Monkey Panel v1.2.3-beta+97022c82). Spider Monkey Panel on that user's pc normally seems only to be using a low amount of memory (but I don't have a full debug report & don't know the identity of image that caused the error).

That user was also using Windows 32 bit (Windows 10 1903) [and I believe on PC with oldish architecture] - these reasons may be why only the occasional user seems to be getting the error?

@TheQwertiest  Do you think these image related issues are due to a bug in Spider Monkey Panel, windows or script? Debug report indicates to me that the script is functioning correctly?

Re: Biography Discussion

Reply #464
@WilB , honestly, I have no idea what's causing it. The thing is, GdiPlus reports OOM error even in cases that don't have anything to do with memory problems, e.g. unsupported image format, unsupported conversion format, error while reading file and etc. And there is no way to get any additional info from this error directly.

So the bug itself might be anywhere: it might be in SMP (I'm doing smth wrong when reading/converting the image), it might be in script (image is being accessed or used incorrectly), it might be caused by the image itself (corrupted format) or it might be caused by Windows (broken GdiPlus).

To narrow the scope we need to create a minimal repro scenario. E.g. if @AndreaT can reliably reproduce the error, then we need to find if this error always happens on the same image (i.e. the cause is the image). If it happens on random images, then the script must be reduced to a minimum lines of code and then we need to get and fix all the data (e.g. music files, urls and etc) to allow us to reproduce the case locally. If the minimal script with fixed data reproduces error reliably on user's machine and not on ours, then the problem is with user's machine configuration (Windows, antivirus software, faulty HDD/SSD or whatever else).

Re: Biography Discussion

Reply #465
@WilB and @TheQwertiest

Hello WilB and TheQwertiest,
I understand that this problem related to the Biography JS has limited affected users and, IMHO, has also a very limited impact on the system behavior and performance.

I am sorry to not be a good developer (I wrote my last line of code in the far 1996), otherwise, for my case, I would just go to that critical section and I would put there a try/catch with catch simply moving forward ignoring that error (keeping in place the previous image or just showing a smiling placeholder).
Biography is not a critical service, when it stops I just try to re-animate it "reloading the JS" (I mean, I give the command reload from the red panel showing the crash).
If this reload can be automatic for any GdiPlus OOM error, it would be the "adequate" (good enough) solution for this problem.
Many thanks for your attention and kind regards, Andrea
 

Re: Biography Discussion

Reply #466
Try catch is very easy to do. But I'm not sure if it will work with real OOMs. I've pm'd you something to try.

Another possibility, if it only effects one or perhaps a few images, is to black listed them (image > black list). After black listing image can be deleted from disc if you wish  - biography should then get an alternative one during next update or if you use force update. If the try catch works, the version I've pm'd will output the identity of the problematical image to the console.

Re: Biography Discussion

Reply #467
Hello WilB, I will try your solution tomorrow and I will update you privately. Many thanks and kind regards, Andrea

Re: Biography Discussion

Reply #468
It seems as if AllMusic album reviews are no-longer returning data correctly.

I'm assuming AllMusic moved the location of their webpage elements around?

Re: Biography Discussion

Reply #469
@WilB
Hello WilB, the try/catch patch is fine. No more crash. Great job.
I sent to your inbox the screeshot of the console.log.
Many thanks!
Kind regards, Andrea

Re: Biography Discussion

Reply #470
I've uploaded  versions of Biography, Library Tree and YouTube Track Manager that are compatible with JScript Panel v 2.3.x+ in the usual locations.

Re: Biography Discussion

Reply #471
New Version: Biography 1.1.2

FIX: AM biography & reviews. Updated to work with site changes.

NEW: Circular artist & cover images (menu > image > circular).

NEW: Use of reflection, border, shadow and circular styles can now be separately applied to artist & cover images (menu > image). Border method has been refined to take account of circular images.

NEW: Image seeker & counter options:
    - Seeker now supports clickable dots for image selection, as well as bar style. Both can be dragged.
    - Counter now optional + can be displayed on its own.
    - Settings: menu > image > seeker & counter.

CHG: Image seeker. Improved positioning over a wider range of layout styles.

NEW: More menu Items:
    -  Circle button now used as visual indicator if more tags are found (requires FontAwesome).
    - "Auto Lock" now available (more... sub menu). "Auto Lock", if enabled, automatically engages the lock on loading items from the menu (history/tag/similar artists/top albums). The lock stops track changes altering the display.

NEW: Ability to set Biography inactive: No internet searching. No text or image loading (SHIFT + right click > menu > inactivate).

CHG: AM reviews and biographies now show the supplementary information if the main review or biography isn't found.

CHG: Various optimisations.

FIX: Cover cycling. Now correctly accepts custom folders: server settings > [COVERS: CYCLE FOLDER].

FIX: Occasional image loading errors.

FIX: Other reported issues.


Re: Biography Discussion

Reply #473
Suggestion:
Add scraping of song genres, styles, moods and themes.

for example, this is a page of a song on AM, it's a new feature they have added to the site in the last few months, so it doesn't have it for every song, but only for most popular artists.

Re: Biography Discussion

Reply #474
It seems as if AllMusic album reviews are no-longer returning data correctly.

I'm assuming AllMusic moved the location of their webpage elements around?

Confirming AllMusic album reviews missing. Began the last weeks and continues in v1.1.2.

 
SimplePortal 1.0.0 RC1 © 2008-2019