kleisauke / wasm-vips

libvips for the browser and Node.js, compiled to WebAssembly with Emscripten.
https://kleisauke.github.io/wasm-vips/
MIT License
519 stars 26 forks source link

fails to run under safari 17.5 for osx #83

Closed adibar closed 1 month ago

adibar commented 1 month ago

library fails for safari 17.5 on osx. Its works on ios. running websites: https://wasm-vips.kleisauke.nl/playground/ https://wasm-vips.kleisauke.nl/test/

the following console errors received and test fails / do not run

[Log] Memory high water: – 0 (test, line 143) [Log] Open files: – 0 (test, line 144) [Log] JPEG support: – "yes" (test, line 146) [Log] JPEG XL support: – "yes" (test, line 147) [Log] AVIF support: – "yes" (test, line 148) [Log] PNG support: – "yes" (test, line 149) [Log] TIFF support: – "yes" (test, line 150) [Log] WebP support: – "yes" (test, line 151) [Log] GIF support: – "yes" (test, line 152) [Log] SVG load: – "yes" (test, line 154) [Log] Text rendering support: – "no" (test, line 156) [Error] GLib (gthread-posix.c): Unexpected error from C library during 'pthread_key_create': Resource temporarily unavailable. Aborting. [Error] worker sent an error! https://wasm-vips.kleisauke.nl/lib/vips.js:14: RuntimeError: Aborted(). Build with -sASSERTIONS for more info. [Error] GLib (gthread-posix.c): Unexpected error from C library during 'pthread_key_create': Resource temporarily unavailable. Aborting. [Error] worker sent an error! https://wasm-vips.kleisauke.nl/lib/vips.js:14: RuntimeError: Aborted(). Build with -sASSERTIONS for more info. [Error] GLib (gthread-posix.c): Unexpected error from C library during 'pthread_key_create': Resource temporarily unavailable. Aborting. [Error] worker sent an error! https://wasm-vips.kleisauke.nl/lib/vips.js:14: RuntimeError: Aborted(). Build with -sASSERTIONS for more info.

Screenshot 2024-10-28 at 11 47 07
kleisauke commented 1 month ago

Did you see https://github.com/kleisauke/wasm-vips/issues/69#issuecomment-2245150645?

adibar commented 1 month ago

I just did. Im running 2019 i9 mac when navigator.hardwareConcurrency == 8 (tested on safari). I have tried running the sample link below: previous error messages do not show. but writeToBuffer - never resumes & cpu is @ constant 100% utilization. also safari process memory go fast to almost 3GB (using safari of course - it does run on chrome).

kleisauke commented 1 month ago

Thanks for confirming. Sounds like it's the same bug as https://bugs.webkit.org/show_bug.cgi?id=276953, which only affects Intel Macs and is still reproducible with Safari 18.

Unfortunately, there's not much more I can do on my end. Please report this to Apple if it continues to be a problem.