Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON argument validation #13

Open
dizzythinks opened this issue Jun 3, 2016 · 1 comment
Open

JSON argument validation #13

dizzythinks opened this issue Jun 3, 2016 · 1 comment

Comments

@dizzythinks
Copy link

dizzythinks commented Jun 3, 2016

Yesterday, I noticed the change between 0.0.3 and 1.0.0 regarding the 'j|--json argument. I was previously specifying a file and it took me a little while to figure out why it was no longer working.

Is it worth adding a validation step that gives a meaningful error if someone passes a file instead of a json key i.e. link to the changelog?

I've got a branch with this working, although I'm not a ruby guy per se so its probably not the best way to do it, plus I see for PR it requires tests etc, not sure how these are done.

https://github.com/dizzythinks/sensu-plugins-opsgenie/tree/check_argument

If this is something worth putting a PR in for in your view let me know.

@majormoses
Copy link
Member

Sorry for no one reaching out sooner, this seems like a very reasonable solution. If you could rebase and PR it that would be awesome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants