grammar update simplifying an AST#47789
Conversation
Kicu
left a comment
There was a problem hiding this comment.
I went over and took a look. I can't say much about the grammar itself. I think the most important thing is that it actually works 😅
I left comments about prettifying the file a bit
|
@abdulrahuman5196 Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
|
@luacmartins it's ready for review |
|
This PR addresses #45293 (comment) and #45293 (comment), Right? Could you please add some details in the author checklist? |
|
@rayane-djouah friendly bump |
|
Will review today |
|
Bug: multiple nodes are created for Screen.Recording.2024-08-26.at.11.37.35.PM.mov |
|
@luacmartins - Is backend ready to handle multi-select values nodes? Bug: Backend is returning empty results when I choose "cash" and "distance" expense types. Screen.Recording.2024-08-27.at.6.21.45.PM.mov |
|
It should be, let me take a look |
|
@289Adam289 we have conflicts' |
|
@rayane-djouah @289Adam289 I put up a PR to fix the API issue. |
|
I improved grammar by implementing @luacmartins suggestions and updated tests to work with new grammar. Currently:
|
|
Nice! I'll resume work on the backend to support the array structure |
luacmartins
left a comment
There was a problem hiding this comment.
Changes LGTM. We need to hold merging this PR until the backend supports the new array syntax.
|
API PR to process arrays is in review. |
|
@289Adam289 in the meantime, I noticed that selecting tags or categories with a Screen.Recording.2024-09-05.at.4.09.19.PM.mov |
|
Backend PR is merged, just waiting on deploy later today. |
|
Backend PR is deployed. Let's test this again and get it merged |
I'vs already solved this issue in #48312 while working on keywords sanitization. |
|
Ah nice! Good to know. |
|
API PR is deployed, let's continue review and hopefully get this PR merged today @rayane-djouah |
Reviewer Checklist
Screenshots/VideosAndroid: NativeHaving problems building Android on main Android: mWeb ChromeScreen.Recording.2024-09-06.at.10.20.13.PM.moviOS: NativeSimulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-09-06.at.22.18.59.mp4iOS: mWeb SafariSimulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-09-06.at.22.14.21.mp4 |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
| const keywordFilter = buildFilter( | ||
| "eq", | ||
| "keyword", | ||
| keywords.map((filter) => filter.right).flat() |
There was a problem hiding this comment.
This line introduces #52923
More details: #52923 (comment)



Details
This pr simplifies AST by creating only one node for multi-select values e.g. category.
It also addresses #45293 (comment)
Fixed Issues
$ #45293 (partial fix)
PROPOSAL:
Tests
search/filters(to check currently unsupported features you can copy grammar to https://peggyjs.org/online.html and test it there)
Offline tests
QA Steps
same steps as Tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
web.mp4
MacOS: Desktop