Skip to content
Snippets Groups Projects
Open patternType:standard mislabels regexp patterns inside parenthesis as literal patterns
  • View options
  • patternType:standard mislabels regexp patterns inside parenthesis as literal patterns

  • View options
  • Open Issue created by Warren Gifford

    Created by: coury-clark

    Search queries with a pattern field that should be interpreted as regexp (inside /.../) will instead parse as literal if the pattern is wrapped in parenthesis. Examples:

    insight[s] is parsed as literal and returns no matches :white_check_mark: /insight[s]/ is parsed as regexp and returns matches :white_check_mark: (/insight[s]/) is parsed as a literal and returns no matches. :x:

    This can be verified by checking the annotations in the query parser.

    (/asdf/) lang:go query.SearchTypeStandard

    msg=annotations: labels="[HeuristicParensAsPatterns Literal]"

    /cc @benvenker @lguychard

    • Merge request
    • Branch

    Activity

    • All activity
    • Comments only
    • History only
    • Newest first
    • Oldest first