You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the Process method, if there is a problem with processing a specific config the method returns a ParseError object. Which includes information such as which key is the problem.
Perhaps using ParseError makes sense, or a new error type that carries just the key and message.
This is useful both from testing as a client and for advanced reporting.
I am trying to test that a certain key is required, and I want to validate that it is the key in question that causes the error.
And if we have a require environment variable that is missing in one of our services, we want to be able to call it out specifically in our operational output, rather than having to parse the string or dump it to the log.
Apologies, I would create a PR, but my office is strict against OSS contributions 😞
The text was updated successfully, but these errors were encountered:
In the Process method, if there is a problem with processing a specific config the method returns a ParseError object. Which includes information such as which key is the problem.
I would like to have a similar granularity of information if a required field is missing.
https://github.com/kelseyhightower/envconfig/blob/master/envconfig.go#L210
Perhaps using ParseError makes sense, or a new error type that carries just the key and message.
This is useful both from testing as a client and for advanced reporting.
I am trying to test that a certain key is required, and I want to validate that it is the key in question that causes the error.
And if we have a require environment variable that is missing in one of our services, we want to be able to call it out specifically in our operational output, rather than having to parse the string or dump it to the log.
Apologies, I would create a PR, but my office is strict against OSS contributions 😞
The text was updated successfully, but these errors were encountered: