matryer / matryer/xbar

xbar.var type string does not support parenthesis in default value for string type in declaration header

Open
#720 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
18.1k
Forks
656
PR merge metrics
No merged PRs in 30d

Description

I am trying to create a flexible Jira plugin that would allow a user to modify the JQL used to query issues, but if I try to provide a default query like the following, the parser fails:
```
string(JIRA_JQL="assignee in (currentUser()) AND resolution = Unresolved"): description
```
![image](https://user-images.githubusercontent.com/6119312/117478519-4458ee00-af2d-11eb-9743-85a12e10338b.png)

I narrowed it down to the parser not liking the `(currentUser())` section. I also tried to escape it (`\(currentUser\(\)\)`), to no avail.

Can this be fixed to ignore special characters between the `"..."`?

If I leave the default value blank, it works by copying the query into the text field in the plugins browser, but I'd really like to be able to provide a default value 🙏

Thanks!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the declaration-header parser and reproduce the failure using the issue's xbar.var example. Verify that parentheses inside the quoted default value are accepted, then confirm the example parses successfully while retaining the default JQL.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
desktop, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.