Skip to content
Latchkey

Crossplane composition function "not found" / unhealthy in CI

A pipeline composition references a Function by name. If no Function package with that name is installed, or its active revision is not healthy, the controller cannot call it and the composition fails.

What this error means

Reconciliation fails with "Function.pkg.crossplane.io \"...\" not found", or kubectl get functions shows HEALTHY False for the function the composition uses.

crossplane
cannot run function pipeline: cannot get function
"function-patch-and-transform": Function.pkg.crossplane.io
"function-patch-and-transform" not found

Common causes

The Function package was never installed

The composition names a function that has no matching Function resource in the cluster, so lookup returns not found.

The function revision is unhealthy

The package installed but its revision failed to pull or start, so it is present but HEALTHY False and cannot serve calls.

How to fix it

Install the function and wait for health

  1. Apply the Function package the composition references.
  2. Wait for the Function to report HEALTHY True.
  3. Then reconcile the XRs that use it.
Terminal
kubectl apply -f function-patch-and-transform.yaml
kubectl wait --for condition=Healthy --timeout=180s \
  function.pkg.crossplane.io/function-patch-and-transform

Diagnose an unhealthy revision

Describe the function revision to find the pull or startup error behind HEALTHY False.

Terminal
kubectl describe functionrevision \
  $(kubectl get functionrevision -o name | head -n1)

How to prevent it

  • Install and health-check all functions before reconciling XRs.
  • Pin function package tags so a bad new revision does not break CI.
  • Reference functions by the exact metadata name the package installs.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →