Fix k8s glue agent crash on unicode input