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

filtering with a property including a hyphen errs with unexpected trailing token - #317

Open
lopezator opened this issue Oct 1, 2024 · 0 comments

Comments

@lopezator
Copy link

Hello!

I am using this filter that is a valid gcp pubsub filter to work with cloudevents (it's working on prod), however, when trying to parse it using pstest (that uses this library to parse the filtering expression) I am unable to parse it.

The filter expression is the following:

attributes.ce-service=user OR attributes.ce-service=accessright

And the error:

^ unexpected trailing token - (1:14)

I tried to quote the expression to try to fix the things out, but that didn't help either.

Input:

"attributes.ce-service=user OR attributes.ce-service=accessright"

Err:

non-bool result type

I guess that is taking that "-" as an operator, but didn't found a way to do it (backslash didn't work).

I had to disable the filtering locally as before this was implemented:

googleapis/google-cloud-go#9015

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant