Skip to content

Fragment parse and serialize implementation does not match module signature #296

Description

@illusionalsagacity

When using rescript@11.1.4, @reasonml-community/graphql-ppx@1.2.4-79d140a5.0, and a WIP branch for rescript-apollo-client with these bsconfig.json settings:

{
  "uncurried": true,
  "ppx-flags": [["@reasonml-community/graphql-ppx/ppx", "-uncurried"]],
}

The Fragments.res module's definitions for parse and serialize are not marked as uncurried functions:

  139 ┆ Js.log2("mutate.update To-Do: ", todo)
  140 ┆ let _unusedRef = writeFragment(
  141 ┆   ~fragment=module(Fragments.TodoItem),
  142 ┆   ~data={
  143 ┆     __typename: todo.__typename,

  Signature mismatch:
  ...
  Values do not match:
    let parse: Raw.t => t (curried)
  is not included in
    let parse: Raw.t => t (uncurried)

This seems to be that generate_fragment_signature doesn't use wrap_sig_uncurried_fn for these, like generate_operation_signature does.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions