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
publicstaticpartialclassLineItemType{internalstaticvoidInitialize(global::HotChocolate.Types.IObjectTypeDescriptor<global::quick_start.Ordering.Types.LineItem>descriptor){constglobal::System.Reflection.BindingFlagsbindingFlags=global::System.Reflection.BindingFlags.Public|global::System.Reflection.BindingFlags.NonPublic|global::System.Reflection.BindingFlags.Static;varthisType=typeof(global::quick_start.Ordering.Types.LineItemType);varbindingResolver=descriptor.Extend().Context.ParameterBindingResolver;global::quick_start.Ordering.Types.LineItemTypeResolvers.InitializeBindings(bindingResolver);descriptor.Field(thisType.GetMember("GetProduct",bindingFlags)[0]).ExtendWith(c =>{c.Definition.SetSourceGeneratorFlags();c.Definition.Resolvers=global::quick_start.Ordering.Types.LineItemTypeResolvers.LineItemType_GetProduct();});descriptor// <---- HERE IS THE ISSUEConfigure(descriptor);}staticpartialvoidConfigure(global::HotChocolate.Types.IObjectTypeDescriptor<global::quick_start.Ordering.Types.LineItem>descriptor);}}
Workaround:
public static partial class LineItemType
{
static partial void Configure(IObjectTypeDescriptor<LineItem> descriptor)
{
descriptor.Ignore(x => x.ProductId);
}
public static Product GetProduct([Parent] LineItem lineItem)
=> new(lineItem.ProductId);
}
What is expected?
The code is generated correctly
What is actually happening?
There is a compilation errros
Relevant log output
Additional context
No response
The text was updated successfully, but these errors were encountered:
Product
Hot Chocolate
Version
14.1.0
Link to minimal reproduction
.
Steps to reproduce
generates:
Workaround:
What is expected?
The code is generated correctly
What is actually happening?
There is a compilation errros
Relevant log output
Additional context
No response
The text was updated successfully, but these errors were encountered: