-
Notifications
You must be signed in to change notification settings - Fork 842
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
Port changes from graphql-js
v0.6.0
#136
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Commit: 6e736bf4733ada6aa15943c0529ed126e8dd8ef1 [6e736bf] Parents: 86db7340be Author: Lee Byron <[email protected]> Date: 8 April 2016 at 9:51:04 AM SGT Labels: HEAD
Commit: cbded829525a68b9e0dab61621992cbf01348981 [cbded82] Parents: dd02973028 Author: Zhaojun Zhang <[email protected]> Date: 26 April 2016 at 2:04:47 AM SGT Committer: Lee Byron <[email protected]>
graphql/graphql-js#364 Commit: 0b72e7038761bec9fb5319cc08ea93ff8b071a9c [0b72e70] Parents: cbded82952 Author: Mike Solomon <[email protected]> Date: 26 April 2016 at 2:37:25 AM SGT Committer: Lee Byron <[email protected]>
graphql/graphql-js#363 * Improve validation error message when field names conflict * Remove extra hint and add unit test
…raphql-go#355) * Add suggestionList to return strings based on how simular they are to the input * Suggests valid fields in `FieldsOnCorrectType` * Suggest argument names * Suggested valid type names * Fix flow and unit test * addressed comments in PR: move file, update comment, filter out more options, remove redundant warning * fix typos * fix lint Commit: 5bc1b2541d1b5767de4016e10ae77021f81310fc [5bc1b25] Parents: 4b08c36e86 Author: Yuzhi <[email protected]> Date: 27 April 2016 at 2:48:45 AM SGT Committer: Lee Byron <[email protected]>
- `quoteStrings` already defined outside on package scope
Commit: 30a783a2a4f100cad0f31085284895bf51aa565a [30a783a] Parents: 5bc1b2541d Author: Lee Byron <[email protected]> Date: 27 April 2016 at 8:49:33 AM SGT
This fixes a bug where an empty "block" list could be skipped by the printer. Commit: ea5b241487c884edb561b12e0a92e947107bbfc1 [ea5b241] Parents: ec05b5404b Author: Lee Byron <[email protected]> Date: 5 May 2016 at 7:26:11 AM SGT Commit Date: 5 May 2016 at 7:26:13 AM SGT
Commit: 88cf354cd65e37fa0793600f6f2a3e6d1b29d21f [88cf354] Parents: 2ac41f6f19 Author: Lee Byron <[email protected]> Date: 7 May 2016 at 3:09:16 AM SGT
sogko
changed the title
Port changes from
[WIP] Port changes from Jun 6, 2016
graphql-js
v0.6.0graphql-js
v0.6.0
Commit: 71b6a4aaecf064c7095bca81cc4285fa74ba175e [71b6a4a] Parents: 980bdf403f Author: Lee Byron <[email protected]> Date: 7 May 2016 at 4:26:20 AM SGT
This implements adding directives to the experimental schema language by extending the *locations* a directive can be used. Notice that this provides no semantic meaning to these directives - they are purely a mechanism for annotating an AST - however future directives which contain semantic meaning may be introduced in the future (the first will be `@deprecated`). Commit: 1b6824bc5df15f8edb259d535aa41a81e2a07234 [1b6824b] Parents: 71b6a4aaec Author: Lee Byron <[email protected]> Date: 7 May 2016 at 5:56:25 AM SGT Labels: HEAD
This allows directives to be defined on schema definitions. Commit: 0aa78f61a2dc150b5ea9ee4f50b68a736796f068 [0aa78f6] Parents: 1b6824bc5d Author: Lee Byron <[email protected]> Date: 7 May 2016 at 7:05:27 AM SGT Labels: HEAD
This adds a new directive as part of the experimental schema language: ``` directive @deprecated(reason: String = "No longer supported") on FIELD_DEFINITION | ENUM_VALUE ``` It also adds support for this directive in the schemaPrinter and buildASTSchema. Additionally exports a new helper `specifiedDirectives` which is encoured to be used when addressing the collection of all directives defined by the spec. The `@deprecated` directive is optimistically added to this collection. While it's currently experimental, it will become part of the schema definition language RFC. Commit: 5375c9b20452801b69dba208cac15d32e02ac608 [5375c9b] Parents: 0aa78f61a2 Author: Lee Byron <[email protected]> Date: 9 May 2016 at 5:56:16 AM SGT Labels: HEAD
This adds a new directive as part of the experimental schema language: ``` directive @deprecated(reason: String = "No longer supported") on FIELD_DEFINITION | ENUM_VALUE ``` It also adds support for this directive in the schemaPrinter and buildASTSchema. Additionally exports a new helper `specifiedDirectives` which is encoured to be used when addressing the collection of all directives defined by the spec. The `@deprecated` directive is optimistically added to this collection. While it's currently experimental, it will become part of the schema definition language RFC. Commit: 5375c9b20452801b69dba208cac15d32e02ac608 [5375c9b] Parents: 0aa78f61a2 Author: Lee Byron <[email protected]> Date: 9 May 2016 at 5:56:16 AM SGT Labels: HEAD
…ogko/0.6.0 * 'sogko/0.6.0' of https://github.com/sogko/graphql: Revert back directives to use `var`; `const` not applicable here Deprecated directive (graphql-go#384)
The functions within this validator did not need to close over any state, which allows them to be pure functions. Commit: 3a01fac4623b37eb7efcdece7a2c33ef74750aeb [3a01fac] Parents: 5375c9b204 Author: Lee Byron <[email protected]> Date: 10 May 2016 at 6:12:08 AM SGT Commit Date: 10 May 2016 at 6:12:11 AM SGT Labels: HEAD
Two more functions from the overlapping-fields validator which now accept arguments rather than closing over them locally. Commit: cf9be874228f4e16762b481d0abed5575f5587db [cf9be87] Parents: 3a01fac462 Author: Lee Byron <[email protected]> Date: 10 May 2016 at 6:22:53 AM SGT Commit Date: 10 May 2016 at 6:24:50 AM SGT
…r than fragment AST node Commit: 688a1ee20db01ca80fdec2189298078380d81ed6 [688a1ee] Parents: cf9be87422 Author: Lee Byron <[email protected]> Date: 10 May 2016 at 9:54:10 AM SGT
This improves the overlapping fields validation performance and improves error reporting quality by separating the concepts of checking fields "within" a single collection of fields from checking fields "between" two different collections of fields. This ensures for deeply overlapping fields that nested fields are not checked against each other repeatedly. Extending this concept further, fragment spreads are no longer expanded inline before looking for conflicts, instead the fields within a fragment are compared to the fields with the selection set which contained the referencing fragment spread. e.g. ```graphql { same: a same: b ...X } fragment X on T { same: c same: d } ``` In the above example, the initial query body is checked "within" so `a` is compared to `b`. Also, the fragment `X` is checked "within" so `c` is compared to `d`. Because of the fragment spread, the query body and fragment `X` are checked "between" so that `a` and `b` are each compared to `c` and `d`. In this trivial example, no fewer checks are performed, but in the case where fragments are referenced multiple times, this reduces the overall number of checks (regardless of memoization). **BREAKING**: This can change the order of fields reported when a conflict arises when fragment spreads are involved. If you are checking the precise output of errors (e.g. for unit tests), you may find existing errors change from `"a" and "c" are different fields` to `"c" and "a" are different fields`. From a perf point of view, this is fairly minor as the memoization "PairSet" was already keeping these repeated checks from consuming time, however this will reduce the number of memoized hits because of the algorithm improvement. From an error reporting point of view, this reports nearest-common-ancestor issues when found in a fragment that comes later in the validation process. I've added a test which fails with the existing impl and now passes, as well as changed a comment. This also fixes an error where validation issues could be missed because of an over-eager memoization. I've also modified the `PairSet` to be aware of both forms of memoization, also represented by a previously failing test. Commit: 4afb263289485897fdfec37aaf6d5f1e5451dcb3 [4afb263] Parents: 688a1ee20d Author: Lee Byron <[email protected]> Date: 11 May 2016 at 5:50:26 AM SGT Labels: HEAD
sogko
changed the title
[WIP] Port changes from
Port changes from Jun 9, 2016
graphql-js
v0.6.0graphql-js
v0.6.0
@sogko Any news regarding this one? |
@sogko any news ? |
* master: gofmt -s executor: add graphql tag Fix ObjectConfig duplicate json tag. Name had a 'description' json tag which was duplicate Minor fix to stop `go vet` from complaining Add 1.7 and tip to build matrix for Go Minor fix to stop `go vet` from complaining README: add Documentation section Fixes tests that was broken with enhancements made to the `lexer` with commit graphql-go#137 Improve lexer performance by using a byte array as source Updated `graphql.Float` coercion - if value type is explicitly `float32`, return `float32` - if value type is explicitly `float64`, return `float64` - if value type is `string`, return `float64` - for everything else, use system-default
2 similar comments
Hi, is something blocking this pull request? |
up, why don't you merge this PR ? |
Merged
closing in favor of: #192 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Based of PR #123
Notable changes:
-This allows directives to be defined on schema definitions.