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

expvar: document Get miss behavior #14150

Closed
aaijazi opened this issue Jan 30, 2016 · 1 comment
Closed

expvar: document Get miss behavior #14150

aaijazi opened this issue Jan 30, 2016 · 1 comment

Comments

@aaijazi
Copy link

aaijazi commented Jan 30, 2016

Spent some time today debugging an issue, which came down to trying to Get an expvar key that doesn't exist.

I would expect expvar.Get("unregistered-key") to panic, just like trying to publish a duplicate key would do. If not, the documentation should be more explicit that Getting a non-existing key will return nil.

@bradfitz bradfitz changed the title expvar.Get should probably error for a missing key expvar: document Get miss behavior Jan 30, 2016
@bradfitz bradfitz added this to the Go1.7 milestone Jan 30, 2016
@gopherbot
Copy link

CL https://golang.org/cl/19915 mentions this issue.

@golang golang locked and limited conversation to collaborators Feb 28, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants