Open sorenisanerd opened 2 years ago
Yeah a timeout seems reasonable; all the same, the terminating OO should come since this is all TCP.
It very much should! I have spent hours and hours trying to pinpoint how they get lost, but to no avail.
On Tue, Oct 18, 2022 at 4:58 PM Felipe Gasper @.***> wrote:
Yeah a timeout seems reasonable; all the same, the terminating OO should come since this is all TCP.
— Reply to this email directly, view it on GitHub https://github.com/FGasper/zmodemjs/issues/33#issuecomment-1283153992, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABHCWXMFXBW6WRQ6LGFCBLWD42RPANCNFSM6AAAAAARIRSPRM . You are receiving this because you authored the thread.Message ID: @.***>
I wonder if it’s a bug in sz
. Maybe it neglects to flush its output buffer or something.
Maybe _consume_ZFIN()
could be where the timeout starts, at the end of which this._on_session_end()
would be called and _bytes_after_OO
gets set to an empty array … and if the usual OO arrives then we clear the timeout.
I suspected sz
, too. I've stared at it a LOT today and it doesn't seem to
be doing anything out of the ordinary.
https://github.com/UweOhse/lrzsz/blob/master/src/lsz.c#L1855-L1857 is
pretty standard.
I haven't been able to trigger it if I run either sz
, bash
, or gotty
under strace
:(
Either way, if sz
is broken, we still need to support current versions of
it.
i have same problem. when i use sz
to download file, sometimes it return ZFIN at the end as described in the picture above, but sometimes it doesn't return and stuck my terminal. it more frequent occurrences when the file is larger than 100MB
it stucks the tty, not my frontend terminal. maybe it is a problem of lrzsz? what can i do for it?
In my computer, it works fine. but when i use it in k8s exec api to access a pod, that error comes
It seems like a relatively common problem that the terminating
OO
fromsz
gets lost or misparsed or something. See all these issues: https://github.com/sorenisanerd/gotty/issues/46 https://github.com/tsl0922/ttyd/issues/239 https://github.com/tsl0922/ttyd/issues/279 https://github.com/Eugeny/tabby/issues/6259 https://github.com/cferdinandi/tabby/issues/132 https://github.com/Eugeny/tabby/issues/5196 https://github.com/trzsz/tabby-trzsz/issues/2 https://github.com/Eugeny/tabby/issues/5132This lets me call
.allow_missing_OO(true)
on the session object which SEEMS to make the problem go away:...but I can't reliably trigger the problem, so my confidence in this approach is not great.
Do you have thoughts on how to address this? The spec suggests that if the
OO
does not arrive, you should just move on with your life after a brief timeout, so maybe we just need to implement that timeout? Just getting stuck in this state doesn't benefit anyone.