pub fn annotated(
policy: &Value,
datapath: PolicyDatapath,
) -> Result<Value, ShapeError>Expand description
The policy with the enforcement verdict annotated.
Absent or null metadata/annotations are the empty case and get
the annotation.
§Errors
ShapeError when the policy, its metadata, or its annotations
holds the wrong JSON type. It used to expect here, and the panic took
the controller task with it, so no policy after the malformed one was
ever annotated.