Skip to content

Resolve query text parsing with brackets#49

Merged
gregjoy1 merged 5 commits intomainfrom
feature/evi-query-categories-bracket-parse-error
Jul 23, 2025
Merged

Resolve query text parsing with brackets#49
gregjoy1 merged 5 commits intomainfrom
feature/evi-query-categories-bracket-parse-error

Conversation

@gregjoy1
Copy link
Owner

This resolves a bug parsing TEXT segments containing brackets within a query context.

For example, X-CATEGORIES:((TESTING)) CATEGORY,CATEGORY TWO should be parsed as:

  • ((TESTING)) CATEGORY
  • CATEGORY TWO

Instead it returned an eof parsing error.

This is because of the query parsing context lookahead parser not being comprehensive enough in handling closing brackets.

This PR resolves this (albeit crudely).

Please review

Copy link
Collaborator

@apexatoll apexatoll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

Not 100% clear on the intricacies of the nom grammar rules, but happy that the tests cover this and the changes look like they've fixed the issue!

@gregjoy1 gregjoy1 merged commit 25714bf into main Jul 23, 2025
8 checks passed
@gregjoy1 gregjoy1 deleted the feature/evi-query-categories-bracket-parse-error branch July 23, 2025 10:23
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

Successfully merging this pull request may close these issues.

2 participants