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

Regression in parser 0.7.3: empty object values no longer parse #744

Closed
goto-bus-stop opened this issue Nov 15, 2023 · 0 comments · Fixed by #745
Closed

Regression in parser 0.7.3: empty object values no longer parse #744

goto-bus-stop opened this issue Nov 15, 2023 · 0 comments · Fixed by #745
Assignees
Labels
apollo-parser bug Something isn't working

Comments

@goto-bus-stop
Copy link
Member

Description

Describe the issue that you're seeing.

Steps to reproduce

Assume a schema with an input object:

input Input {
  optional: Boolean
}
type Query {
  field(arg: Input): Int
}

And a query like this with an empty object:

{
  field(arg: {})
}

Expected result

Should parse without errors.

Actual result

Error: syntax error: expected Object Value
   ╭─[/dev/fd/11:8:15]
   │
 8 │   field(arg: {})
   │               ┬
   │               ╰── expected Object Value
───╯

Environment

  • apollo-rs crate: apollo-parser
  • Crate version: 0.7.3
@goto-bus-stop goto-bus-stop added bug Something isn't working triage labels Nov 15, 2023
@goto-bus-stop goto-bus-stop self-assigned this Nov 15, 2023
goto-bus-stop added a commit that referenced this issue Nov 16, 2023
* fix(parser): object values can be empty, fixes #744

* spaces

* changelog

* links
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apollo-parser bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant