Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v0.5.0: CEL decodeb64: unexpected type 'bytes' #608

Closed
bitsofinfo opened this issue Jun 14, 2020 · 1 comment · Fixed by #609
Closed

v0.5.0: CEL decodeb64: unexpected type 'bytes' #608

bitsofinfo opened this issue Jun 14, 2020 · 1 comment · Fixed by #609
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@bitsofinfo
Copy link
Contributor

bitsofinfo commented Jun 14, 2020

Expected Behavior

I have an CEL overlay interceptor and this should work (docs say decodeb64 returns a string)

              - key: intercepted.id
                expression: "body.item1.decodeb64().parseJSON().appName"

Actual Behavior

"caller":"sink/sink.go:145","msg":"failed to evaluate overlay expression 'body.item1.decodeb64().parseJSON().appName': unexpected type 'bytes' passed to parseJSON"

The docs say decodeb64() yields a string, but this error seems to indicate its passing along bytes

Workaround: string(body.item1.decodeb64()).parseJSON().appName

@vdemeester
Copy link
Member

/kind bug

@tekton-robot tekton-robot added the kind/bug Categorizes issue or PR as related to a bug. label Jun 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants