Open JRice15 opened 2 years ago
Found an even cleaner example of the issue. Running the following script works as expected:
using PortAudio
in_stream = PortAudioStream(1, 0; latency = 0.01)
throw(DivideError())
unless, you supply the --threads N
argument to Julia, where N>1. Then it fails silently at the throw
.
Thanks for the report! This would be good to fix. We probably should run these examples as part of CI to make sure they run.
As a relative newcomer to Julia and this package, I thought I'd try out an example script.
audiometer.jl
works fine.measure_latency.jl
does not.I've narrowed the issue down to the
write
call on line 37. It seems that an exception is thrown here, but some combination of this package's problems with multi-threading (#81) and/or error suppression (#89) makes it error out silently at this spot (meaning, the script just exits, showing no output, but with an exit code of 1).If I wrap the call like so:
I get this output:
The fact that it fails silently seems to me to be the more serious issue here, though I'm also curious why this apparent type mismatch occurs.
Version info: