Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ANTLR only allow traversal on certain expressions #26068

Merged
merged 5 commits into from
Nov 21, 2024

Conversation

briantu
Copy link
Contributor

@briantu briantu commented Nov 21, 2024

Summary & Motivation

We discovered some ambiguity caused by traversal expressions that may cause parser to return an unexpected asset selection. For example, currently the parser reads *key:a and key:b* as *(key:a and key:b)*. We believe this is unintuitive, so we've decided to force the traversal tokens to only apply to the expression they are immediately next to.

@briantu briantu marked this pull request as ready for review November 21, 2024 00:34
Copy link

github-actions bot commented Nov 21, 2024

Deploy preview for dagit-core-storybook ready!

✅ Preview
https://dagit-core-storybook-bs1me6ump-elementl.vercel.app
https://briantu-fix-antlr-traversal-precedence.core-storybook.dagster-docs.io

Built with commit af6777c.
This pull request is being automatically deployed with vercel-action

@briantu briantu force-pushed the briantu/fix-antlr-traversal-precedence branch from d804f52 to d77e549 Compare November 21, 2024 00:40
@briantu briantu changed the base branch from master to briantu/hookup-antlr-antlr-frontend November 21, 2024 00:40
@briantu briantu force-pushed the briantu/hookup-antlr-antlr-frontend branch from 4ae9c9a to 1a3b80c Compare November 21, 2024 00:42
@briantu briantu force-pushed the briantu/fix-antlr-traversal-precedence branch from d77e549 to 9b0e0d2 Compare November 21, 2024 00:42
Copy link
Contributor

@salazarm salazarm left a comment

Choose a reason for hiding this comment

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

do we need a similar change in the python visitor?

@briantu briantu changed the title Fix ANTLR UpAndDownTraversalExpression precedence ANTLR only allow traversal on certain expressions Nov 21, 2024
Copy link
Contributor

@salazarm salazarm left a comment

Choose a reason for hiding this comment

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

nice!!

@briantu briantu force-pushed the briantu/hookup-antlr-antlr-frontend branch from 1a3b80c to 41011f3 Compare November 21, 2024 20:13
@briantu briantu force-pushed the briantu/fix-antlr-traversal-precedence branch 2 times, most recently from 66b1463 to 80ac002 Compare November 21, 2024 20:17
Copy link
Contributor Author

briantu commented Nov 21, 2024

Merge activity

  • Nov 21, 3:44 PM EST: A user started a stack merge that includes this pull request via Graphite.
  • Nov 21, 3:57 PM EST: Graphite rebased this pull request as part of a merge.
  • Nov 21, 3:58 PM EST: A user merged this pull request with Graphite.

@briantu briantu changed the base branch from briantu/hookup-antlr-antlr-frontend to graphite-base/26068 November 21, 2024 20:50
@briantu briantu changed the base branch from graphite-base/26068 to master November 21, 2024 20:55
@briantu briantu force-pushed the briantu/fix-antlr-traversal-precedence branch from 80ac002 to af6777c Compare November 21, 2024 20:56
@briantu briantu merged commit 616f81a into master Nov 21, 2024
1 of 2 checks passed
@briantu briantu deleted the briantu/fix-antlr-traversal-precedence branch November 21, 2024 20:58
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