graphql-to-reason
graphql-to-reason copied to clipboard
Running example.
Version Package version latest Describe the bug A clear and concise description of what the bug is.
Building an running the example, here https://github.com/Coobaha/graphql-to-reason/tree/master/examples throw the following error:
> bsb -make-world -w
>>>> Start compiling
[7/7] Building src/SchemaTypes_builder.mlast.d
[2/4] Building src/SchemaTypes-GraphqlToReasonBasicExample.cmj
We've found a bug for you!
/Users/prisc_000/Downloads/Coobaha-examples_basic/src/SchemaTypes.re 1:40-6:1
1 │ include SchemaTypes_builder.MakeSchema({
2 │ module Scalars = {};
. │ ...
5 │ type directiveResolver('payload);
6 │ });
Signature mismatch:
...
Type declarations do not match:
type resolver('parent, 'args, 'fieldType, 'result) =
('parent, 'args) => Js.Promise.t('result)
is not included in
type resolver('payload, 'fieldType, 'result)
File "/Users/prisc_000/Downloads/Coobaha-examples_basic/src/SchemaTypes.re", line 3, characters 3-101:
Actual declaration
They have different arities.
>>>> Finish compiling(exit: 1)
reproduction here.https://github.com/idkjs/coobaha-repro
Expected behaviour A clear and concise description of what you expected to happen.
Expected behaviour was for project to compile.
Disregard. Working now. Must have run some wrong commands. Thank you.
In case anyone else comes across this, for whatever reason, the above error is resolved by updating all the deps in package.json to latest, running clean and dev again. Might be that there was a bump in package number for this package since the one used in the example. Run rm package-lock.json then npx npm-check-updates to update all the deps. Then npm run bsb:clean then npm run bsb:dev. Working example here: https://github.com/Coobaha/graphql-to-reason/pull/8