Coder Social home page Coder Social logo

hubot-rss-reader's Introduction

Hubot RSS Reader

RSS Reader for each Chat Channels, works with Hubot.

Circle CI

screen shot

Requirements

Install

% npm install hubot-rss-reader -save
% npm install coffee-script@">=1.10.0" -save

edit external-script.json

["hubot-rss-reader"]

Configure (ENV vars)

export DEBUG=hubot-rss-reader*      # debug print
export HUBOT_RSS_INTERVAL=600       # 600 sec (default)
export HUBOT_RSS_HEADER=:sushi:     # RSS Header Emoji (default is "sushi")
export HUBOT_RSS_USERAGENT=hubot    # (default is "hubot-rss-reader/#{package_version}")
export HUBOT_RSS_PRINTSUMMARY=true  # print summary (default is "true")
export HUBOT_RSS_PRINTIMAGE=false   # print image in summary (default is "true")
export HUBOT_RSS_PRINTERROR=false   # print error message (default is "true")
export HUBOT_RSS_IRCCOLORS=true     # use IRC color message (default is "false")
export HUBOT_RSS_LIMIT_ON_ADD=false # limit printing entries on add new feed. (default is 5)

Usage

add

hubot rss add https://github.com/shokai.atom
# or
hubot rss register https://github.com/shokai.atom

delete

hubot rss delete https://github.com/shokai.atom
hubot rss delete #room_name

list

hubot rss list
hubot rss dump

Test

% npm install

% grunt
# or
% npm test

hubot-rss-reader's People

Contributors

motchang avatar pastelinc avatar patrys avatar raucao avatar sairoutine avatar shokai avatar uk-ar avatar yuya-oc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hubot-rss-reader's Issues

dont work with irc

like the topic say:

[13:16:09] [~Jaglag]: !rss add http://feeds.feedburner.com/blogspot/rkEL
[13:16:18] [~Jaglag]: !rss add http://postillion.soup.io/
[13:17:15] [~Jaglag]: !rss add http://golem.de.dynamic.feedsportal.com/pf/578068/http://rss.golem.de/rss.php?feed=RSS2.0
[13:17:27] [~Jaglag]: Butlerz rss register http://golem.de.dynamic.feedsportal.com/pf/578068/http://rss.golem.de/rss.php?feed=RSS2.0
[13:17:35] [~Jaglag]: Butlerz rss add http://golem.de.dynamic.feedsportal.com/pf/578068/http://rss.golem.de/rss.php?feed=RSS2.0
[13:19:08] [~Jaglag]: !rss list
[13:19:08] [@butlerz]: nothing

here the heroku logs:

2015-01-06T12:17:18.310925+00:00 app[web.1]: [Tue Jan 06 2015 12:17:18 GMT+0000 (UTC)] ERROR TypeError: Object http://go
lem.de.dynamic.feedsportal.com/pf/578068/http://rss.golem.de/rss.php?feed=RSS2.0 has no method 'then'
2015-01-06T12:17:18.310928+00:00 app[web.1]: at TextListener.callback (/app/node_modules/hubot-rss-reader/scripts/hubo
t-rss-reader.coffee:67:5, :81:52)
2015-01-06T12:17:18.310930+00:00 app[web.1]: at TextListener.Listener.call (/app/node_modules/hubot/src/listener.coffe
e:27:7, :23:14)
2015-01-06T12:17:18.310931+00:00 app[web.1]: at Robot.receive (/app/node_modules/hubot/src/robot.coffee:197:9, :14
2:33)
2015-01-06T12:17:18.310952+00:00 app[web.1]: at IrcBot.Adapter.receive (/app/node_modules/hubot/src/adapter.coffee:66:
5, :47:25)
2015-01-06T12:17:18.310954+00:00 app[web.1]: at Client. (/app/node_modules/hubot-irc/src/irc.coffee:257:7,
:342:21)
2015-01-06T12:17:18.310955+00:00 app[web.1]: at Client.emit (events.js:106:17)
2015-01-06T12:17:18.310957+00:00 app[web.1]: at Client. (/app/node_modules/hubot-irc/node_modules/irc/lib/i
rc.js:471:22)
2015-01-06T12:17:18.310958+00:00 app[web.1]: at Client.emit (events.js:95:17)
2015-01-06T12:17:18.310960+00:00 app[web.1]: at /app/node_modules/hubot-irc/node_modules/irc/lib/irc.js:658:22
2015-01-06T12:17:18.310962+00:00 app[web.1]: at Array.forEach (native)
2015-01-06T12:17:18.310963+00:00 app[web.1]: at Socket. (/app/node_modules/hubot-irc/node_modules/irc/lib/i
rc.js:655:15)
2015-01-06T12:17:18.310964+00:00 app[web.1]: at Socket.emit (events.js:95:17)
2015-01-06T12:17:18.310966+00:00 app[web.1]: at Socket. (stream_readable.js:765:14)
2015-01-06T12:17:18.310969+00:00 app[web.1]: at Socket.emit (events.js:92:17)
2015-01-06T12:17:18.310970+00:00 app[web.1]: at emitReadable
(_stream_readable.js:427:10)
2015-01-06T12:17:18.310973+00:00 app[web.1]: at readableAddChunk (_stream_readable.js:166:9)
2015-01-06T12:17:18.310971+00:00 app[web.1]: at emitReadable (_stream_readable.js:423:5)
2015-01-06T12:17:18.310974+00:00 app[web.1]: at Socket.Readable.push (_stream_readable.js:128:10)
2015-01-06T12:17:18.310976+00:00 app[web.1]: at TCP.onread (net.js:529:21)
2015-01-06T12:17:18.311233+00:00 app[web.1]: [Tue Jan 06 2015 12:17:18 GMT+0000 (UTC)] DEBUG Message 'Butlerz rss add ht
tp://golem.de.dynamic.feedsportal.com/pf/578068/http://rss.golem.de/rss.php?feed=RSS2.0' matched regex //./i/
2015-01-06T12:17:18.310977+00:00 app[web.1]:
2015-01-06T12:18:51.403110+00:00 app[web.1]: [Tue Jan 06 2015 12:18:51 GMT+0000 (UTC)] DEBUG From Jaglag to #butlerz: !r
ss list
2015-01-06T12:18:51.404178+00:00 app[web.1]: [Tue Jan 06 2015 12:18:51 GMT+0000 (UTC)] DEBUG Message '!rss list' matched

Remove Picture links

Hi
Is it possible to just remove the Picture from the feed links:

[00:50:53] [+Butlerz]: ​##News## Frauenfußball-WM: DFB-Spielerinnen erreichen Halbfinale ​- [Sport - Sportnachrichten, Fußball und Formel 1]
[00:50:54] [+Butlerz]: ​http://sz.de/1.2540705
[00:50:55] [+Butlerz]: http://polpix.sueddeutsche.com/polopoly_fs/1.2540744.1435357498!/httpImage/image.jpg_gen/derivatives/135x135/image.jpg
[00:50:56] [+Butlerz]: Dramatischer Sieg in Montreal: Die deutschen Fußballerinnen gewinnen gegen Frankreich im Elfmeterschießen

we dont need that 3 line.
Where can i remove that?

find RSS

find RSS if HTML page added.

Design

shokai > hubot rss add http://shokai.org/blog/
hubot > http://shokai.org/blog/ is not a feed, found some feeds.
             http://shokai.org/blog/feed

No updates

I won't get any updates, on my feeds.

  hubot:
    image: rocketchat/hubot-rocketchat
    environment:
      - ROCKETCHAT_URL=rocketchat:8065
      - ROCKETCHAT_ROOM=''
      - HUBOT_RSS_INTERVAL=60
      - ROCKETCHAT_USER=hubot
      - LISTEN_ON_ALL_PUBLIC=true
      - ROCKETCHAT_PASSWORD=<my super secret password>
      - BOT_NAME=hubot
      - EXTERNAL_SCRIPTS=hubot-help,hubot-rss-reader
    links:
      - rocketchat:rocketchat
    ports:
      - "127.0.0.1:3001:8080"

Won't start polling on hubot restart with file-brain

When you use built-in file-brain as a brain, RSS polling won't restart on hubot restart.

Reproduction step:

  1. Start a hubot with hubot-rss-reader enabled with file-brain
  2. hubot rss add <url>
  3. It responds registered <url> and starts polling properly
  4. Shutdown and restart the hubot
  5. It does not start polling again (checker start message does not show up on log)

(Tested with zulip-adapter and hipchat-adapter)

And I actually found a cause.

Polling for RSS starts with loaded event from robot.brain (here).
But emission of this event is somewhat tricky (explained here, in Japanese tho).

In some brains the event might be fired on startup, so it can be used to kick the polling.

But there are some brains loaded event won't fired until something changed within brain. Such as file-brain. With these brains your hubot won't restart RSS polling after restart.

My ad-hoc patch is to just start run() function regardless of loaded event. Since it rarely fails to load file-brain.

  ## wait until connect redis
  #robot.brain.once 'loaded', ->
  run = (opts) ->
    logger.info "checker start"
    checker.check opts
    .then ->
      logger.info "wait #{process.env.HUBOT_RSS_INTERVAL} seconds"
      setTimeout run, 1000 * process.env.HUBOT_RSS_INTERVAL
    , (err) ->
      logger.error err
      logger.info "wait #{process.env.HUBOT_RSS_INTERVAL} seconds"
      setTimeout run, 1000 * process.env.HUBOT_RSS_INTERVAL

  run()

Of course this fix is too ugly to be merged, there could be more sophisticated ways to ensure restart.

RSSChecker doesn't work with hubot-mongodb-brain

When I run hubot-rss-reader with hubot-mongodb-brain, I get

[Tue May 31 2016 10:53:21 GMT+0900 (JST)] INFO MongoDB connected
  hubot-rss-reader checker start +0ms
[Tue May 31 2016 10:53:21 GMT+0900 (JST)] ERROR TypeError: Cannot call method 'then' of undefined
  at run (/home/<username>/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:74:7, <js>:94:35)
  at Brain.<anonymous> (/home/<username>/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:83:5, <js>:103:14)
  at Brain.g (events.js:180:16)
  at Brain.emit (events.js:95:17)
  at Brain.mergeData (/home/<username>/hubot/node_modules/hubot/src/brain.coffee:92:5, <js>:82:19)
  at /home/<username>/hubot/node_modules/hubot-mongodb-brain/scripts/hubot-mongodb-brain.coffee:47:9, <js>:41:23
  at handleCallback (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/lib/utils.js:96:12)
  at /home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/lib/cursor.js:839:16
  at handleCallback (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:159:5)
  at setCursorNotified (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:511:3)
  at /home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:582:16
  at queryCallback (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:220:18)
  at [object Object].Callbacks.emit (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/topologies/server.js:119:3)
  at [object Object].messageHandler (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/topologies/server.js:371:23)
  at Socket.<anonymous> (/home/<username>/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connection.js:301:22)
  at Socket.emit (events.js:95:17)
  at Socket.<anonymous> (_stream_readable.js:765:14)
  at Socket.emit (events.js:92:17)
  at emitReadable_ (_stream_readable.js:427:10)
  at emitReadable (_stream_readable.js:423:5)
  at readableAddChunk (_stream_readable.js:166:9)
  at Socket.Readable.push (_stream_readable.js:128:10)
  at TCP.onread (net.js:529:21)

It's not reproducible when using file-brain.coffee.

ERROR TypeError: undefined is not a function

I've been unable to use hubot-rss-reader with mongodb. I get the same error as #39 and #51 but I am already running coffeescript v1.10.0

hubot@chat:~$ coffee --version
CoffeeScript version 1.10.0

[Sun Jun 05 2016 19:38:41 GMT+0000 (UTC)] ERROR TypeError: Cannot read property 'then' of undefined
  at run (/home/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:74:7, <js>:94:34)
  at Brain.<anonymous> (/home/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:83:5, <js>:103:14)
  at Brain.g (events.js:199:16)
  at Brain.emit (events.js:107:17)
  at Brain.mergeData (/home/hubot/node_modules/hubot/src/brain.coffee:92:5, <js>:82:19)
  at /home/hubot/node_modules/hubot-mongodb-brain/scripts/hubot-mongodb-brain.coffee:47:9, <js>:41:23
  at handleCallback (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/lib/utils.js:96:12)
  at /home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/lib/cursor.js:839:16
  at handleCallback (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:159:5)
  at setCursorDeadAndNotified (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:501:3)
  at nextFunction (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:652:7)
  at [object Object].Cursor.next [as _next] (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:693:3)
  at fetchDocs (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/lib/cursor.js:835:10)
  at /home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/lib/cursor.js:858:7
  at handleCallback (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:159:5)
  at nextFunction (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:683:5)
  at /home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:585:7
  at queryCallback (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/cursor.js:220:18)
  at [object Object].Callbacks.emit (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/topologies/server.js:119:3)
  at [object Object].messageHandler (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/topologies/server.js:397:23)
  at Socket.<anonymous> (/home/hubot/node_modules/hubot-mongodb-brain/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connection.js:302:22)
  at Socket.emit (events.js:107:17)
  at readableAddChunk (_stream_readable.js:163:16)
  at Socket.Readable.push (_stream_readable.js:126:10)
  at TCP.onread (net.js:538:20)

TypeError occured

When I add feed in local environment, TypeError occured.

Hubot> hubot rss add https://github.com/shokai.atom
[Sun Feb 01 2015 12:07:39 GMT+0900 (JST)] INFO hubot-rss-reader: add https://github.com/shokai.atom
[Sun Feb 01 2015 12:07:39 GMT+0900 (JST)] ERROR TypeError: Object https://github.com/shokai.atom has no method 'then'
  at TextListener.callback (/Users/cutmail/src/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:97:5, <js>:134:52)
  at TextListener.Listener.call (/Users/cutmail/src/hubot/node_modules/hubot/src/listener.coffee:27:7, <js>:23:14)
  at Robot.receive (/Users/cutmail/src/hubot/node_modules/hubot/src/robot.coffee:197:9, <js>:142:33)
  at Shell.Adapter.receive (/Users/cutmail/src/hubot/node_modules/hubot/src/adapter.coffee:66:5, <js>:47:25)
  at Interface.<anonymous> (/Users/cutmail/src/hubot/node_modules/hubot/src/adapters/shell.coffee:56:15, <js>:100:23)
  at Interface.emit (events.js:95:17)
  at Interface._onLine (readline.js:203:10)
  at Interface._line (readline.js:532:8)
  at Interface._ttyWrite (readline.js:761:14)
  at ReadStream.onkeypress (readline.js:100:10)
  at ReadStream.emit (events.js:98:17)
  at emitKey (readline.js:1096:12)
  at ReadStream.onData (readline.js:841:14)
  at ReadStream.emit (events.js:95:17)
  at ReadStream.<anonymous> (_stream_readable.js:765:14)
  at ReadStream.emit (events.js:92:17)
  at emitReadable_ (_stream_readable.js:427:10)
  at emitReadable (_stream_readable.js:423:5)
  at readableAddChunk (_stream_readable.js:166:9)
  at ReadStream.Readable.push (_stream_readable.js:128:10)
  at TTY.onread (net.js:529:21)

Problem with rss / atom working fine

Hi,

I dont know if its a problem with the hubot or the irc module or your script but the normal rss feed have some problems:

[08:21:44] [+Butlerz]: ​##News## Korruption in Rom: Knietief im M�ll ​- [SPIEGEL ONLINE - Schlagzeilen]
[08:21:45] [+Butlerz]: ​http://www.spiegel.de/politik/ausland/rom-renzi-kaempft-gegen-mafia-muell-und-korruption-a-1040296.html#ref=rss

vs atom feed:

05:45:53] [+Butlerz]: ​##News## Rom: Monti reicht Rücktritt ein ​- [Politik - aktuelle Nachrichten auf SZ.de]
[05:45:54] [+Butlerz]: ​http://sz.de/1.1557002

limiting premision?

is there a way to limit premisions? What i mean is to dissalow normal users to excute rss add/delete/register.

Error: Object has no method 'then' at run

Found while trying to address #18 once again.

This error shows in my log just a few seconds after I start hubot.

[Sat Nov 15 2014 20:10:11 GMT-0500 (EST)] ERROR TypeError: Object #<Object> has no method 'then'
  at run (/Users/colin/Source/metamesh/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:32:7, <js>:27:35)
  at [object Object]._onTimeout (/Users/colin/Source/metamesh/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:41:5, <js>:36:14)
  at Timer.listOnTimeout [as ontimeout] (timers.js:112:15)

Cannot find module '../build/Debug/iconv.node' when starting with systemd

I do not understand this, maybe someone here has an idea to this :(
If i start without systemd, everything is just fine.

ERROR Unable to load /home/bot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader: 
Error: Cannot find module '../build/Debug/iconv.node'
Unit]
After=syslog.target network.target

[Service]
User=bot
SyslogIdentifier=bot
Type=simple
WorkingDirectory=/home/bot

Restart=always
RestartSec=10

ExecStart=/bin/sh start.sh

[Install]
WantedBy=multi-user.target

SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode

When I start hubot with the hubot-rss-reader external script, hubot dies with this error:

ERROR Unable to load /home/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader: SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:373:25)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (/home/hubot/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object. (/home/hubot/node_modules/hubot-rss-reader/node_modules/debug/src/index.js:9:19)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (/home/hubot/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object. (/home/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:18:14)
at Object. (/home/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:14:1)
at Module._compile (module.js:409:26)
at Object.loadFile (/home/hubot/node_modules/coffee-script/lib/coffee-script/register.js:16:19)
at Module.load (/home/hubot/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Robot.loadFile (/home/hubot/node_modules/hubot/src/robot.coffee:355:18)
at /home/hubot/node_modules/hubot-rss-reader/index.coffee:12:17
at FSReqWrap.cb [as oncomplete] (fs.js:212:19)

forgets links

I did register a link to the bot but he forgot it after a few minutes.

ETIMEDOUT

Sometimes I get this message with a lot of my feeds (integrated into rocket chat): [ERROR] https://any.url/latest.rss - ETIMEDOUT.

Is there a way, so I can see log files? Or can someone help me debug this?

cleanup HTML tag in description

  • remove HTML tag in description(summary)
  • extract href attribute of img tags

config

% export HUBOT_RSS_HTML=true  # not remove HTML tag

RSS add multiple entries

Is it possible to add multiple rss stream? or example rss add site1.atom site2.atom site3.atom ?

If not, that would be a cool feature :)

add feeds silent

add feeds without the last 5 news feed posts.
You can see everything in log if its added correctly or not?

feed parse error

  hubot-rss-reader:rss-checker fetch http://github-trends.ryotarai.info/rss/github_trends_go_daily.rss +3ms
  hubot-rss-reader:rss-checker Error: Not a feed
  at FeedParser.handleEnd (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/main.js:125:13)
  at SAXStream.emit (events.js:92:17)
  at Object.SAXStream._parser.onend (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:184:8)
  at emit (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:615:33)
  at end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:654:3)
  at Object.SAXParser.end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:149:24)
  at SAXStream.end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:234:16)
  at FeedParser._flush (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/main.js:1028:15)
  at FeedParser.<anonymous> (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_transform.js:135:12)
  at FeedParser.g (events.js:180:16)
  at FeedParser.emit (events.js:92:17)
  at finishMaybe (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_writable.js:372:12)
  at endWritable (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_writable.js:379:3)
  at FeedParser.Writable.end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_writable.js:357:5)
  at Request.onend (stream.js:79:10)
  at Request.emit (events.js:117:20)
  at IncomingMessage.<anonymous> (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/request/request.js:998:12)
  at IncomingMessage.emit (events.js:117:20)
  at _stream_readable.js:929:16
  at process._tickCallback (node.js:419:13)
 +71ms
  hubot-rss-reader { error: [Error: Not a feed], feedUrl: 'http://github-trends.ryotarai.info/rss/github_trends_go_daily.rss' } +4ms
[Wed Sep 03 2014 23:38:10 GMT+0900 (JST)] ERROR TypeError: Cannot read property 'url' of undefined
  at RSSChecker.<anonymous> (/Users/sho/src/nodejs/hubot/hubot-rss-reader/scripts/hubot-rss-reader.coffee:50:35)
  at RSSChecker.emit (events.js:95:17)
  at /Users/sho/src/nodejs/hubot/hubot-rss-reader/scripts/rss-checker.coffee:80:16
  at FeedParser.<anonymous> (/Users/sho/src/nodejs/hubot/hubot-rss-reader/scripts/rss-checker.coffee:40:7)
  at FeedParser.emit (events.js:117:20)
  at FeedParser.handleError (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/main.js:146:8)
  at FeedParser.handleEnd (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/main.js:126:17)
  at SAXStream.emit (events.js:92:17)
  at Object.SAXStream._parser.onend (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:184:8)
  at emit (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:615:33)
  at end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:654:3)
  at Object.SAXParser.end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:149:24)
  at SAXStream.end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/sax/lib/sax.js:234:16)
  at FeedParser._flush (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/main.js:1028:15)
  at FeedParser.<anonymous> (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_transform.js:135:12)
  at FeedParser.g (events.js:180:16)
  at FeedParser.emit (events.js:92:17)
  at finishMaybe (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_writable.js:372:12)
  at endWritable (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_writable.js:379:3)
  at FeedParser.Writable.end (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/feedparser/node_modules/readable-stream/lib/_stream_writable.js:357:5)
  at Request.onend (stream.js:79:10)
  at Request.emit (events.js:117:20)
  at IncomingMessage.<anonymous> (/Users/sho/src/nodejs/hubot/hubot-rss-reader/node_modules/request/request.js:998:12)
  at IncomingMessage.emit (events.js:117:20)
  at _stream_readable.js:929:16
  at process._tickCallback (node.js:419:13)

ERROR TypeError: undefined is not a function

I'm getting this when I start my hubot up..
It's running in a docker container.

Thu, 06 Aug 2015 17:17:34 GMT hubot-rss-reader checker start
[Thu Aug 06 2015 13:17:34 GMT-0400 (EDT)] ERROR TypeError: undefined is not a function
  at run (/opt/archie/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:73:7, <js>:92:35)
  at Brain.<anonymous> (/opt/archie/hubot/node_modules/hubot-rss-reader/scripts/hubot-rss-reader.coffee:82:5, <js>:101:14)
  at Brain.g (events.js:199:16)
  at Brain.emit (events.js:129:20)
  at Brain.set (/opt/archie/hubot/node_modules/hubot/src/brain.coffee:31:5, <js>:35:12)
  at robotStore (/opt/archie/hubot/node_modules/hubot-react/scripts/react.js:228:22)
  at start (/opt/archie/hubot/node_modules/hubot-react/scripts/react.js:262:3)
  at Brain.<anonymous> (/opt/archie/hubot/node_modules/hubot-react/scripts/react.js:313:5)
  at Brain.<anonymous> (/opt/archie/hubot/node_modules/hubot-react/node_modules/underscore/underscore.js:831:21)
  at Brain.g (events.js:199:16)
  at Brain.emit (events.js:129:20)
  at Brain.mergeData (/opt/archie/hubot/node_modules/hubot/src/brain.coffee:92:5, <js>:82:19)
  at /opt/archie/hubot/node_modules/hubot-redis-brain/src/redis-brain.coffee:49:9, <js>:28:23
  at try_callback (/opt/archie/hubot/node_modules/hubot-redis- brain/node_modules/redis/index.js:548:9)
  at RedisClient.return_reply (/opt/archie/hubot/node_modules/hubot-redis-brain/node_modules/redis/index.js:630:13)
  at ReplyParser.<anonymous> (/opt/archie/hubot/node_modules/hubot-redis-brain/node_modules/redis/index.js:282:14)
  at ReplyParser.emit (events.js:107:17)
  at ReplyParser.send_reply (/opt/archie/hubot/node_modules/hubot-redis-brain/node_modules/redis/lib/parser/javascript.js:300:10)
  at ReplyParser.execute (/opt/archie/hubot/node_modules/hubot-redis-brain/node_modules/redis/lib/parser/javascript.js:203:22)
  at RedisClient.on_data (/opt/archie/hubot/node_modules/hubot-redis-brain/node_modules/redis/index.js:504:27)
  at Socket.<anonymous> (/opt/archie/hubot/node_modules/hubot-redis-brain/node_modules/redis/index.js:82:14)
  at Socket.emit (events.js:107:17)
  at readableAddChunk (_stream_readable.js:163:16)
  at Socket.Readable.push (_stream_readable.js:126:10)
  at TCP.onread (net.js:538:20)

Any ides what is going on?

Error with deleting rooms in irc

[13:00:20] [~Jaglag]: !rss dump
[13:00:22] [Butlerz]: {
[13:00:23] [Butlerz]: "#butlerz": [
[13:00:24] [Butlerz]: "http://www.heise.de/newsticker/heise-top-atom.xml"
[13:00:25] [Butlerz]: ],
.....
[13:00:37] [~Jaglag]: !rss delete #butlerz
[13:00:38] [Butlerz]: room #butlerz is not exists

add multiple Feeds

separate with "\n"

# register multiple Feeds separate with line-break
hubot rss add https://github.com/shokai.atom\n
hubot rss add http://shokai.org/blog/feed\n
hubot rss add http://b.hatena.ne.jp/shokai/rss

Running on Heroku, no output when adding

I've added hubot-rss-reader to my hubot running on Heroku with the IRC adapter. I've enabled debugging.

2014-10-05T16:54:13.499773+00:00 app[web.1]: [Sun Oct 05 2014 16:54:13 GMT+0000 (UTC)] INFO Got private message from rhettigan: rss list
2014-10-05T16:54:18.279478+00:00 app[web.1]: [Sun Oct 05 2014 16:54:18 GMT+0000 (UTC)] INFO Got private message from rhettigan: rss register http://rss.uptimerobot.com/u175401-f89932dc6d4f430e17f3a172459432e7
2014-10-05T16:54:18.338141+00:00 app[web.1]: Sun, 05 Oct 2014 16:54:18 GMT hubot-rss-reader add http://rss.uptimerobot.com/u175401-f89932dc6d4f430e17f3a172459432e7
2014-10-05T16:54:44.106340+00:00 app[web.1]: [Sun Oct 05 2014 16:54:44 GMT+0000 (UTC)] INFO Got private message from rhettigan: rss add http://rss.uptimerobot.com/u175401-f89932dc6d4f430e17f3a172459432e7
2014-10-05T16:54:44.165050+00:00 app[web.1]: Sun, 05 Oct 2014 16:54:44 GMT hubot-rss-reader add http://rss.uptimerobot.com/u175401-f89932dc6d4f430e17f3a172459432e7
2014-10-05T16:56:07.380508+00:00 app[web.1]: [Sun Oct 05 2014 16:56:07 GMT+0000 (UTC)] INFO Got private message from rhettigan: rss add http://cad.cx/
2014-10-05T16:56:07.400154+00:00 app[web.1]: Sun, 05 Oct 2014 16:56:07 GMT hubot-rss-reader add http://cad.cx/

I would expect the adds of uptimerobot.com to yield some kind of debugging message effecting that they had been added or not. I would expect the add of cad.cx to yield a failure, as it's not an RSS feed.

add option to change color output on feed

instead of:
export HUBOT_RSS_IRCCOLORS=true # use IRC color message (default is "false")
true or false let the ppl change the color "standard" purple blue yellow bold/white etc etc.?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.