mikeal / spider

Programmable spidering of web sites with node.js and jQuery

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

test fail

hackervera opened this issue · comments

Object [ null ] has no method 'trigger'

which test?

mini:tests tyler$ node test_nytimes.js

/Users/tyler/spider/main.js:60
document.trigger(
^
TypeError: Object [ null ] has no method 'trigger'
at /Users/tyler/spider/main.js:60:16
at Spider._handler (/Users/tyler/spider/main.js:184:5)
at [object Object].callback (/Users/tyler/spider/main.js:159:12)
at IncomingMessage. (/Users/tyler/node_modules/request/main.js:260:21)
at IncomingMessage.emit (events.js:81:20)
at HTTPParser.onMessageComplete (http.js:132:23)
at Socket.ondata (http.js:1212:22)
at Socket._onReadable (net.js:678:27)
at IOWatcher.onReadable as callback

Works for me (awesome!) but I get a few dozen blank entries like this, after the successful ones:

{ title: '', articleBody: '', photos: [], body: '' }

Followed by:

FATAL ERROR: CALL_AND_RETRY_2 Allocation failed - process out of memory

the test it's a boolean test at the moment, it shouldn't throw an exception one, but i can't reproduce this.