Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

close being emitted without end or error #74

Open
sstchur opened this issue May 2, 2023 · 0 comments
Open

close being emitted without end or error #74

sstchur opened this issue May 2, 2023 · 0 comments

Comments

@sstchur
Copy link

sstchur commented May 2, 2023

It's possible that I'm misunderstanding, but I'm working with tar-fs, which I understand depends on streamx, and I have a case where (intermittently), I'm seeing a close event fire on a tarStream, but error never fires and neither does end. This actually ends up causing the script to hang (presumably because the consumer is waiting for an end event that it will never get, now that close has emitted).

Am I correct in thinking that (generally), close should not be firing before end in most "normal" cases? And if it does, it means something has probably gone wrong (forcibly closed the stream?). But if that's the case, shouldn't the close event pass in an error object? Or shouldn't there ALSO have been an errror event emitted? I get neither, so it's incredibly difficult to find the root cause.

Any insight would be appreciated. Unfortunately, the code where I'm seeing this happen is large and complex, and I don't (yet) have any easy way to extract out a simple repro. I will of course, update this issue if I'm able to provide code that repros.

In the meantime, I was just hoping to get some general insight on how streamx fundamentally works (or is supposed to work) from the author.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant