question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`Expected character: )` in Regex + Boolean operator expression (Invalid filter)

See original GitHub issue

This is my JSON { "a": { "b": "cdefg" } }

This is my JayWay JsonPath expression [?((($.a.b =~ /cd.*/) && ($.a.b == 'cdefg')))]

I’m getting an error Expected character: ) when running here Any reason why ?

BTW, if i’m changing sides of operands, like so [?((($.a.b == 'cdefg') && ($.a.b =~ /cd.*/)))] it matches OK

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
moshevicommented, May 6, 2021

I see there’s a fix for that on https://github.com/json-path/JsonPath/pull/661/commits/e68e9f2f9b04d741b85797335ac78f1a8c7317c2 Any idea when that will be released?

1reaction
Chaoyismcommented, Apr 25, 2021

Hii moshevi, sorry for the delay.

I have verified the problem you pointed out, and I am trying to fix it now.

Anyone else is interested in this issue is welcome to take part in 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Regular expression to filter special characters not working
I want a function that returns true if a given string does NOT match. You can negate the character set. (Note the ^...
Read more >
SyntaxError: invalid regular expression flag "x" - MDN Web Docs
The JavaScript exception "invalid regular expression flag" occurs when the flags in a regular expression contain any flag that is not one of:...
Read more >
Regular Expressions :: Eloquent JavaScript
A regular expression consisting of only nonspecial characters simply represents that sequence of characters.
Read more >
regex - Functions - Configuration Language | Terraform
The regex function applies a regular expression to a string and returns the ... The pattern is a string containing a mixture of...
Read more >
Best Practices for Regular Expressions in .NET - Microsoft Learn
Unconstrained input is a text that originates from an unreliable source, such as a web user, and might not follow a predefined or...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found