lenra-io / lenra-io/query-parser
[Task] regex operator
Nobody has claimed this yet.
- Dominant language
- Elixir
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
What should be done
According to https://github.com/mongodb-js/mongodb-language-model/blob/master/grammar.pegjs#L449, regex is a part of leaf_value.
Grammar
- implement extended_json_value & ejson_regex
Exec
In the idea, we will have the Exec? call with pos "leaf-value" and value an object: {regex: , options: }
run pattern on return true / false
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the parser entry points for extended_json_value and ejson_regex, using the regex definition in grammar.pegjs as the reference. Trace how a leaf-value Exec call receives an object containing regex and options. Done means regex values parse and the Exec call returns true or false when the pattern is run.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- elixir
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100