Closed stevefister closed 8 years ago
Looks like a bug. PR welcome.
I tried replacing abort() method with destroy(). That stops the error, but then nothing is received. I'm not much of a help as I'm very new to node 😐
I believe the steps to recreate this:
Using github master for my code, same thing happens
node-tweet-stream/lib/twitter.js:287 this.stream.abort()
@nathanbowser not entirely sure if there are best practices clearing filters while something is coming in. Any ideas as to why this is happening? Thank you for good work.
Yea, I figured it out. Fix coming shortly.
I had trouble getting a test to reproduce this, but I think it's because you're hitting a twitter rate limit, which aborts the stream in the response callback.
+ node-tweet-stream@1.9.1
Hey Nathan, thanks for fixing this :) I think its a great library. Im having a lot of trouble with this bug, so ill be sure to test.
@jeveloper awesome, please let me know!
@jeveloper Did you ever get a chance to try out my fix?
Yes it does work :)
Any ideas?? Thanks!
/mnt/sda1/node-tweet-stream/node_modules/node-tweet-stream/lib/twitter.js:270 this.stream.abort() ^ TypeError: Cannot call method 'abort' of null at Twitter.abort (/mnt/sda1/node-tweet-stream/node_modules/node-tweet-stream/lib/twitter.js:270:15) at null. (/mnt/sda1/node-tweet-stream/node_modules/node-tweet-stream/lib/twitter.js:257:10)
at Request.EventEmitter.emit (events.js:95:17)
at IncomingMessage. (/mnt/sda1/node-tweet-stream/node_modules/node-tweet-stream/node_modules/request/request.js:965:12)
at IncomingMessage.EventEmitter.emit (events.js:95:17)
at readableAddChunk (_stream_readable.js:132:14)
at IncomingMessage.Readable.push (_stream_readable.js:113:10)
at HTTPParser.parserOnBody as onBody
at CleartextStream.socketOnData as ondata
at CleartextStream.read as _read