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
/// to a list of <see href="GQLProblemDetails">GQLProblemDetails</see>.
274
274
letprivateresolverError path ctx e = ctx.Schema.ParseError path e |> List.map (GQLProblemDetails.OfFieldExecutionError (path |> List.rev))
275
275
// Helper functions for generating more specific <see href="GQLProblemDetails">GQLProblemDetails</see>.
276
-
letprivatenullResolverError name path ctx = resolverError path ctx (GraphQLException<| sprintf "Non-Null field %s resolved as a null!" name)
277
-
letprivatecoercionError value tyName path ctx = resolverError path ctx (GraphQLException<| sprintf "Value '%O' could not be coerced to scalar %s" value tyName)
278
-
letprivateinterfaceImplError ifaceName tyName path ctx = resolverError path ctx (GraphQLException<| sprintf "GraphQL Interface '%s' is not implemented by the type '%s'" ifaceName tyName)
279
-
letprivateunionImplError unionName tyName path ctx = resolverError path ctx (GraphQLException(sprintf "GraphQL Union '%s' is not implemented by the type '%s'" unionName tyName))
280
-
letprivatedeferredNullableError name tyName path ctx = resolverError path ctx (GraphQLException(sprintf "Deferred field %s of type '%s' must be nullable" name tyName))
281
-
letprivatestreamListError name tyName path ctx = resolverError path ctx (GraphQLException(sprintf "Streamed field %s of type '%s' must be list" name tyName))
276
+
letprivatenullResolverError name path ctx = resolverError path ctx (GQLMessageException<| sprintf "Non-Null field %s resolved as a null!" name)
277
+
letprivatecoercionError value tyName path ctx = resolverError path ctx (GQLMessageException<| sprintf "Value '%O' could not be coerced to scalar %s" value tyName)
278
+
letprivateinterfaceImplError ifaceName tyName path ctx = resolverError path ctx (GQLMessageException<| sprintf "GraphQL Interface '%s' is not implemented by the type '%s'" ifaceName tyName)
279
+
letprivateunionImplError unionName tyName path ctx = resolverError path ctx (GQLMessageException(sprintf "GraphQL Union '%s' is not implemented by the type '%s'" unionName tyName))
280
+
letprivatedeferredNullableError name tyName path ctx = resolverError path ctx (GQLMessageException(sprintf "Deferred field %s of type '%s' must be nullable" name tyName))
281
+
letprivatestreamListError name tyName path ctx = resolverError path ctx (GQLMessageException(sprintf "Streamed field %s of type '%s' must be list" name tyName))
282
282
283
283
letprivateresolved name v :AsyncVal<ResolverResult<KeyValuePair<string, obj>>>= AsyncVal.wrap <| Ok(KeyValuePair(name, box v), None,[])
284
284
@@ -353,7 +353,7 @@ let rec private direct (returnDef : OutputDef) (ctx : ResolveFieldContext) (path
/// Returns an argument by provided name. If argument was not found a GraphQL exception will be thrown.
12
+
/// <exception cref="GraphQLException">When argument with the name not found in the Args.</exception>
13
+
memberx.Arg(name :string):'t =
14
+
match Map.tryFind name x.Args with
15
+
| Some found ->downcast found
16
+
| None -> raise (GQLMessageException $"Argument '%s{name}' was not provided within context of a field '%s{x.ExecutionInfo.Identifier}'. Check if it was supplied within GraphQL query.")
0 commit comments