https://toitlang.org/ logo
Cause of PREVIOUS_READER_NOT_FINISHED?
# help
g
Copy code
[network] INFO: closing {connection: wifi-0}
[network] INFO: closed {connection: wifi-0}
[artemis.scheduler] INFO: job stopped {job: synchronize}
NETWORK: Listener exception: 'PREVIOUS_READER_NOT_FINISHED' for msg:'null'
Is this due to Artemis contention or something else? Thank you. Happens here:``` msg := null error := catch: msg = ws.receive // wait for web socket traffic if error: catch: ws.close // Force cleanup of the potentially "corrupted" object logger.error "NETWORK: Listener exception: '$error' for msg:'$msg'" ```
f
Is this snippet from your code? If yes, then holding on to
network
(the one you receive from
net.open
) should keep the network open. Could it be that you "lose" it and the GC then claims that your program doesn't need network anymore?
g
Gemini claims one part of my sending code was timed so perfectly with the pings from the cloud it caused PREVIOUS_READER_NOT_FINISHED which is a contention issue. Not knowing what triggers that error in toit, I can't really argue. However, it seems to be gone so we are declaring victory and going home.
f
I had another user run into it, but I think there, holding on to the
network
object did the trick. If you find something more reproducible please let me know.