Skip to content

hubot-auth just won't work for me #36

Open
@lwhitworth

Description

@lwhitworth

Having a few issues (aplogies if I'm just being stupid):

When I run "what roles do I have" hubot returns nothing, debug looks like:

[Wed Jul 06 2016 13:27:50 GMT+0100 (BST)] DEBUG From: 1gu5otii6baaaaamanz3h1kear, To: 5cdpm7euotaaaaaa1ca5agt8je
[Wed Jul 06 2016 13:27:50 GMT+0100 (BST)] DEBUG Received message from user_mcuser: what roles do I have
[Wed Jul 06 2016 13:27:50 GMT+0100 (BST)] DEBUG Message sent to hubot brain.
[Wed Jul 06 2016 13:27:50 GMT+0100 (BST)] DEBUG Message 'bob what roles do I have' matched regex //^\s*[@]?bob[:,]?\s*(?:what roles? do(es)? @?([^\s]+) have\?*$)/i/; listener.options = { id: null }
[Wed Jul 06 2016 13:27:50 GMT+0100 (BST)] DEBUG Executing listener callback for Message 'bob what roles do I have'
[Wed Jul 06 2016 13:27:50 GMT+0100 (BST)] ERROR TypeError: Cannot read property 'length' of undefined
  at TextListener.callback (/opt/hubot/node_modules/hubot-auth/src/auth.coffee:136:17)
  at /opt/hubot/node_modules/hubot/src/listener.coffee:65:12
  at allDone (/opt/hubot/node_modules/hubot/src/middleware.coffee:44:37)
  at /opt/hubot/node_modules/hubot/node_modules/async/lib/async.js:274:13
  at Object.async.eachSeries (/opt/hubot/node_modules/hubot/node_modules/async/lib/async.js:142:20)
  at Object.async.reduce (/opt/hubot/node_modules/hubot/node_modules/async/lib/async.js:268:15)
  at /opt/hubot/node_modules/hubot/src/middleware.coffee:49:13
  at nextTickCallbackWith0Args (node.js:420:9)
  at process._tickCallback (node.js:349:13)

Additionally despite having set the env variable:

echo $HUBOT_AUTH_ROLES
admin=1gu5otii6baaaaamanz3h1kear

Running "list assigned roles" returns:
@bob Sorry, only admins can list assigned roles.

Any tips on what might be occuring?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions