Skip to content

Miscellaneous feedback regarding FieldSelectionMap scalar validation #171

Open
@glen-84

Description

@glen-84
  1. A schema is provided in the introduction, but it's not used consistently. Section 6.3.4 and 6.3.5 counter-examples use altered schemas, and section 6.3.7 uses two different UserInput types, neither of which are in the reference schema. It would make the tests cleaner and more consistent if either all rules referenced the same schema, or all rules used their own schema.
  2. 6.3.3 Type Reference Is Possible:
    • The terminology here is difficult to follow:
      • "If segment is a type reference" – Type reference meaning <TypeName>? If so, then this is only part of a PathSegment, or part of a Path. Michael suggested that we could consider using the term "type condition" (as used with fragments). Should this be something like "If segment includes a type condition"? But this won't handle Paths with a type condition?
      • "Let parentType be the type of the parent of the segment" – for PathSegments, this is the return type of the referenced field, there's no "parent of the segment"? For Path, it would be the output type.
      • "Let applicableTypes be the intersection of GetPossibleTypes(type) and GetPossibleTypes(parentType)" – is it necessary to get the possible types of the type? Does it not just need to be a possible type of parentType?
    • This section is missing examples.
  3. 6.3.4 Values of Correct Type:
    • The terminology is very confusing. What does value/literal values/value literals refer to here?
    • Michael mentioned that the types should the same (not just coercible).
    • How should differences in nullability be handled? If the input side is non-nullable, can the output side be nullable, and vice versa?
  4. 6.3.5 Selected Object Field Names and 6.3.6 Selected Object Field Uniqueness:
    • The examples appear to be incorrect:
      • The arguments are not input object types.
      • The FieldSelectionMaps are not using braces.
  5. 6.3.7 Required Selected Object Fields:
    • There is no mention of @oneOf here, which is mentioned in section 2.4 @is.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions