-
Notifications
You must be signed in to change notification settings - Fork 657
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
UploadV2 fails to recognize csv-stringify stream as a ReadableStream and errors #1586
Comments
Update, I think it may be because the check is checking if it is an |
Hi @elrob! 👋 Thank you for sharing the steps to reproduce this error – I am seeing this same thing. Good call with the Testing this against the changes from #1577 seems to remove the error and successfully upload |
Hey @elrob, it's been a while! (Hope you remember me😸) Thanks a lot for taking the time to report this! |
Hey @seratch ! I wondered whether to ping you as I saw that you were a top contributor on this repo but I thought I'd be patient and polite first. 😆 Of course I remember you! You're still the emoji for |
Related but not the same issue...
|
@elrob As you observed, |
Thank you! |
This was resolved in #1577 and will be shipped (shortly!) in |
Thank you! I can confirm that uploadV2 is now working for us with a stream and using Thanks for the quick response and turnaround! |
(Filling out the following with as much detail as you can provide will help us solve your issue sooner.)
Packages:
Select all that apply:
@slack/web-api
@slack/rtm-api
@slack/webhooks
@slack/oauth
@slack/socket-mode
@slack/types
Reproducible in:
The Slack SDK version
Node.js runtime version
OS info
Linux
Steps to reproduce:
stream.Transform
which extendsDuplex
which extendsReadable
which implementsNodeJS.ReadableStream
if
statement:node-slack-sdk/packages/web-api/src/file-upload.ts
Line 262 in acef8cf
(file as any) instanceof ReadStream
must be returningfalse
, I believe.Expected result:
API successfully uploads the file from the stream.
It worked fine before switching to uploadV2.
Actual result:
error:
The text was updated successfully, but these errors were encountered: