-
-
Notifications
You must be signed in to change notification settings - Fork 147
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
How to know when writeStream is completed? #147
Comments
I found a way to get a proper event when it's done but requires a code change in webdav-client in
|
I'm not sure what That being said, |
You're right. Here is what I need to know and it looks like one of your tests have the same need. I need to know when the "WriteStream" is totally and completely done doing its thing, including passing off to Besides my use in AWS Lambda I think knowing when it's completed is a good thing to have anyway. I just don't know what the best option is here with the way it's set up.
|
I've flagged this as a bug, which I'll hopefully get around to shortly. I'm also happy for someone else to take a look at it! |
Same issue here. The |
I pass the a readable stream as arg
It works for me. I can now know when the uploading is completed. |
@bingliu221 Your solution actually sounds quite logical. There's no way to really know the length of the stream if it's still open, so sending it as a header is pointless. I would accept a PR for the |
Released in 3.1.0 |
I need to know when a
createWriteStream
has fully completed.I tried
on
events forend
,finish
andunpipe
and all of them get called immediately and before the write is complete.The text was updated successfully, but these errors were encountered: