hubot-archive / hubot-pager-me

PagerDuty integration for Hubot
https://www.npmjs.com/package/hubot-pager-me
MIT License
73 stars 92 forks source link

Case sensitivity of schedule names #40

Closed mcg closed 9 years ago

mcg commented 9 years ago

This is likely a limitation with the PD API, but it would be helpful if "who is on call for schedule" didn't care about the case of the schedule name. For example we have a "SysOps" schedule and "who is on call for sysops" doesn't find it, but "who is on call for SysOps" does.

technicalpickles commented 9 years ago

I think the code for this is around https://github.com/hubot-scripts/hubot-pager-me/blob/master/src/scripts/pagerduty.coffee#L601-L607 . Should be able to just change == to compare the lowercased query to the lowercased name.

That assumes that the PagerDuty API isn't case-sensitive, and that it doesn't allow you to have two schedules like "schedule" and "SCHEDULE".

technicalpickles commented 9 years ago

@stephenyeargin I've posthumously added you as a collaborator for your work in https://github.com/hubot-scripts/hubot-pager-me/pull/30 and https://github.com/hubot-scripts/hubot-pager-me/pull/32 . If you send me your npm login, I can add you so you can release.

Some notes & advice around that: continue to use PRs for the extra :eyes: . Use semantic versioning. You can release with grunt release:<patch|minor|major>. If you have any questions or whatever, you can just open an issue and cc @hubot-scripts/hubot-pager-me

stephenyeargin commented 9 years ago

@technicalpickles Cool. I'll take a look at this as well. My NPM username is same as :octocat:

stephenyeargin commented 9 years ago

Addressed in #41.

technicalpickles commented 9 years ago

My NPM username is same as :octocat:

Added!

mcg commented 9 years ago

Fix seems to work great, thanks!

technicalpickles commented 9 years ago

This was released in 2.1.3.