mirror of https://github.com/helm/helm
postRendererPlugin.Run type-asserted output.Message with the unchecked, single-value form (output.Message.(schema.OutputMessagePostRendererV1)), unlike the equivalent, already-guarded assertion in getterPlugin.Get (pkg/getter/plugingetter.go), and then called outputMessage.Manifests.Bytes() without checking whether Manifests was nil. A plugin whose Invoke() returns a message with a nil Manifests field (which is exactly what json.Unmarshal produces for a WASM/extism/v1 plugin's output when its JSON response omits the "manifests" key or sets it to null) crashes the whole helm process with an unrecovered nil-pointer-dereference panic instead of a clean error. This is a distinct, unrecovered-panic edge case of the already-known, still-open "WASM post-renderer plugins receive empty manifests" defect (#31832, attempted fix in stale/closed #31834): that report's own echo-plugin reproducer round-trips {"manifests":{}} rather than {"manifests":null}/omitted, which unmarshals to a non-nil empty Buffer and therefore only hits the existing graceful "produced empty output" error, not this panic. Add the same ok-checked type assertion getterPlugin.Get already uses, and treat a nil Manifests the same as an empty one. Signed-off-by: zanarelli <zanarelli.dev@gmail.com>pull/32502/head
parent
a8ab76e86f
commit
ad0040261d
Loading…
Reference in new issue