In Helm templates (which use the Go templating language), when you're trying to access a value like:
yaml
{{ get (lookup "apps/v1" "Deployment" $input_namespace $input_deployment_name).spec.template.metadata.annotations "checksum/config" }}
and the .annotations map doesn't exist (e.g., is nil), get will fail.
To safely access this field and return a default value (e.g., an empty string or "default-value"), you should protect the lookup chain and ensure that each level exists.
You can use default and conditional checks like this:
✅ Option 1: Safe Access with get, default, and and