Closed justinabrahms closed 2 years ago
@justinabrahms reason
can (and SHOULD) contain more than just errors. It can also contain something signifying why a flag evaluation occurred the way it did. For example "SPECIFIC_USER_OVERRIDE"
or "TARGETING_RULE_MATCH"
. LD for example has such reasons. The reason should only indicate an error if there was an error. The error code
gets specific as to the nature of the error.
See: https://github.com/open-feature/spec/blob/main/specification/flag-evaluation/flag-evaluation.md#requirement-146 (reason in normal execution)
I'm closing this since there's been no further discussion, and it seems (based on the :+1: ) the answer is satisfactory.
Now that we've changed the wording around reason vs error code, things are a bit foggy for me.
How are they different? Without error code being an enum.. I don't really get how that's different than 1.4.8
Requirement 1.4.7
Some example error codes include: "TARGETING_KEY_MISSING", "PROVIDER_NOT_READY", "FLAG_NOT_FOUND", "PARSE_ERROR", "TYPE_MISMATCH", or "GENERAL".
Requirement 1.4.8