samples icon indicating copy to clipboard operation
samples copied to clipboard

Function in version "v1beta2" cannot be handled as a Function: strict decoding error: unknown field "spec.serving.runtime"

Open ToviHe opened this issue 2 years ago • 1 comments

knative/hello-world-python strict decoding error: unknown field "spec.serving.runtime" error occurred when running function.yaml image image

ToviHe avatar Oct 30 '23 02:10 ToviHe

Hi, thank you for bringing this up. I ran into a similar error when trying out this example and was stumped at first. The root cause is that the spec.serving.runtime field has been deprecated in the v1beta2 version of OpenFunction, but Knative Serving is still used by default for HTTP functions.

For anyone facing a similar issue: To resolve this error while continuing to use OpenFunction as intended, simply remove the spec.serving.runtime line. OpenFunction will automatically detect and configure Knative behind the scenes (assuming Knative is installed).

natlv avatar Jul 05 '25 08:07 natlv