Closed bnoordhuis closed 1 month ago
While I see that there is currently no way to report the exceptions, what's annoying is I cannot reproduce the original issue, at least on macOS. It seems to repro all the time in the CI though. Any chance it's related to the timer source not being accurate enough since it's a virtualized environment?
quickjs only needs millisecond resolution. It seems sorta unlikely if perhaps not completely impossible that the timer source is too coarse.
Let me add some printf^Wconsole.log statements to see in what order the timeouts actually run.
quickjs only needs millisecond resolution. It seems sorta unlikely if perhaps not completely impossible that the timer source is too coarse.
ECMA only specifies millisecond resolution, but precise timings benefit from a finer resolution, at least microsecond if not nanosecond, so we should preserve a simple way to retrieve a precision clock. This however seems unrelated to the current issue.
Example: assert triggered from timer callback should exit with a non-zero error but doesn't. quickjs-libc.c calls
js_std_dump_error()
and trucks on.Originally posted by @saghul in https://github.com/quickjs-ng/quickjs/issues/338#issuecomment-2032266845