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

Handle "N/A" as valid value of the XOFFBATT field. Fixes #2. #3

Merged
merged 3 commits into from
Apr 12, 2017
Merged

Handle "N/A" as valid value of the XOFFBATT field. Fixes #2. #3

merged 3 commits into from
Apr 12, 2017

Conversation

rschaeuble
Copy link
Contributor

No description provided.

@rschaeuble
Copy link
Contributor Author

This pull request fixes #2 in the minimal way.

We could consider parsing all time fields in this way, instead of just XOFFBATT, just to be safe.
What do you think, @mdlayher?

@mdlayher
Copy link
Owner

Your suggestion seems reasonable to me, though I'd be curious to know exactly which fields apcupsd can return "N/A" for.

@mdlayher
Copy link
Owner

I'll merge this as-is unless you'd like to make additional changes. Just let me know.

@rschaeuble
Copy link
Contributor Author

As you seem to be fine with it, I'd like to change all date parsing over to the new method. Should be a matter of only a few minutes.

@mdlayher
Copy link
Owner

Go for it!

… strings.

This is just to be on the safe side, because how NIS handles time values doesn't seem
completely logical/consistent.
@rschaeuble
Copy link
Contributor Author

Done.

@mdlayher
Copy link
Owner

LGTM!

@mdlayher mdlayher merged commit 2fdb254 into mdlayher:master Apr 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants