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

Only allow one alias per predicate. #4236

Merged
merged 1 commit into from
Nov 13, 2019
Merged

Conversation

martinmr
Copy link
Contributor

@martinmr martinmr commented Nov 4, 2019

There's a bug in the parser that allows queries like this to be
considered correct.

{
  q(func: uid(1)) {
    name: name_pred: other_stuff
  }
}

The parser should return an error for such queries since it's trying to
define more than one alias.

Fixes #4235


This change is Reviewable

There's a bug in the parser that allows queries like this to be
considered correct.

```
{
  q(func: uid(1)) {
    name: name_pred: other_stuff
  }
}
```

The parser should return an error for such queries since it's trying to
define more than one alias.
@martinmr martinmr requested review from manishrjain and a team as code owners November 4, 2019 20:18
Copy link
Contributor

@manishrjain manishrjain left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 2 of 2 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@martinmr martinmr merged commit 5e7406b into master Nov 13, 2019
@martinmr martinmr deleted the martinmr/alias-parse-bug branch November 13, 2019 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

expected error for syntax error, but did not get one
2 participants