get_node on a Server.LLM node after a failed inference returned an empty
meta.error field even though the node’s state was ERROR. Errors on LLM
nodes were silently discarded.
krill-sdk 0.0.48 (and 0.0.49, which was published from a different
krill-oss PR before the interface-refactor landed) implements
updateMetaWithError as a 29-arm exhaustive when (meta) { ... else -> meta }.
LLMMetaData was never added to that chain, so every call fell through to
else -> meta, returning the original metadata unchanged. ServerNodeManager
called updateMetaWithError(node.meta, cause) unconditionally, so the node
entered ERROR state but its meta.error stayed empty.
The krill-oss fix (PR #148 — abstract NodeMetaData.withError() replacing the
when-chain) was committed to krill-oss but shipped to Maven Central under a
version that had already been published (0.0.49 was taken by a prior PR), so
the bug persisted in the artifact.
krill-sdk in gradle/libs.versions.toml from 0.0.48 → 0.0.49.server/.../NodeMetaDataServerExt.kt: internal extension
NodeMetaData.applyError(error) that handles LLMMetaData via copy(error = error)
and delegates all other types to the SDK’s updateMetaWithError.ServerNodeManager.setErrorState to call node.meta.applyError(cause)
instead of updateMetaWithError(node.meta, cause).NodeMetaDataServerExt.kt is explicitly marked for removal once krill-sdk ships
abstract NodeMetaData.withError() (tracked in krill-oss#146).
NodeMetaData subtype must be added to the SDK’s updateMetaWithError
dispatch immediately, or the error message will silently vanish. The krill-oss
fix (abstract interface method, compile-time enforced) eliminates this class of
bug permanently once it ships.javap -c) before
relying on it.NodeMetaDataServerExtTest (or equivalent) covering every server-side
node type that goes through error-state promotion, so a missing arm fails a
test rather than silently returning stale metadata.