[streamcz] Use compat_str
[streamcz] Workaround CertificateError