I run into this issue occasionally:
(sharp:29151): GLib-CRITICAL **: 20:51:15.820: g_hash_table_lookup: assertion 'hash_table != NULL' failed
A little bit of research has shown that it is due to a process being terminated midway through an operation. In my case, it'd be very helpful if I could suppress this warning message. Is such a thing possible?
Hello, if something beyond your control is calling process.exit() then this will result in an unclean shutdown of both libuv and libvips-managed threads and therefore data they "own".
If you can't prevent the unclean shutdown you'll probably want to prevent libvips spawning threads via sharp.concurrency(1) to reduce the likelihood of this occurring.
I鈥檝e been able to use kill instead of exit to silence these warnings while not eliminating the algorithm's concurrency. Probably not the most elegant solution, but I needed the child processes to exit once one of them found a solution.
Another possible solution might be to add logic that waits for sharp.counters().process to reach zero before exiting. http://sharp.pixelplumbing.com/en/stable/api-utility/#counters