You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit dcd4a25
Browse filesBrowse the repository at this point in the historyBrowse files
Fix the same shape without a parent service field, bump to 6.2.3
The replacer fix alone left `srv.Get(new Key(ctx.A, ctx.B))` broken on a plain
service field with nothing above it - it turned "An item with the same key has
already been added" into "Argument types do not match", because the extracted
expression is still the whole construction.
Walk through New/MemberInit in ExpressionExtractor.ProcessPotentialLeaf so each
member read credits itself, which is what the class doc-comment already
describes. Keep the ExpressionReplacer change: the extractor still emits a
repeat for a conditional argument, which hits the identical crash.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+6-1Lines changed: 6 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,13 @@
1
+
# 6.2.3
2
+
3
+
## Fixes
4
+
5
+
- Fixed `An item with the same key has already been added` when a service field's resolver builds an object from more than one context member as an argument to the service call - `(ctx, srv) => srv.Get(new Key(ctx.A, ctx.B))`. `ExpressionExtractor` credited both member reads to the enclosing construction rather than to themselves, so it emitted the same `Expression` instance twice under the one name and `ExpressionReplacer` added each of them to a dictionary keyed by node identity. A construction is now walked through rather than treated as a leaf, so each read is extracted on its own. `ExpressionReplacer` also tolerates a repeated expression, which the extractor still emits for other shapes (a conditional argument, where the branch reads are both credited to the conditional).
6
+
1
7
# 6.2.2
2
8
3
9
## Fixes
4
10
5
-
- Fixed `An item with the same key has already been added` when a service field's resolver builds an object from more than one context member as an argument to the service call (`(ctx, srv) => srv.Get(new Key(ctx.A, ctx.B))`) and that field is selected below another service field. `ExpressionExtractor` credits both member reads to the enclosing construction rather than to themselves, so it emits the same `Expression` instance twice under the one name - which its own contract allows - and `ExpressionReplacer` was adding each of them to a dictionary keyed by node identity.
6
11
- Fixed a field whose dotnet type is a nullable value type (`Instant?`, `DateTime?`, `int?`) resolving to `default(T)` instead of `null`, for a query that also selects an async field. Results are rebuilt after any async field is awaited, and each member's new type was taken from the resolved value's runtime type.
Copy file name to clipboardExpand all lines: src/EntityGraphQL/EntityGraphQL.csproj
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@
4
4
<LangVersion>14.0</LangVersion>
5
5
<AssemblyName>EntityGraphQL</AssemblyName>
6
6
<PackageId>EntityGraphQL</PackageId>
7
-
<PackageVersion>6.2.2</PackageVersion>
7
+
<PackageVersion>6.2.3</PackageVersion>
8
8
<Description>A GraphQL library for .NET. Compiles queries into .NET Expressions (LinqProvider) for runtime execution against object graphs. E.g. against an ORM data model (EntityFramework or others) or just an in-memory object.</Description>
0 commit comments