ChilliCream / graphql-platform

Welcome to the home of the Hot Chocolate GraphQL server for .NET, the Strawberry Shake GraphQL client for .NET and Banana Cake Pop the awesome Monaco based GraphQL IDE.
https://chillicream.com
MIT License
5.27k stars 748 forks source link

Compiling produces error #6633

Closed dirkil closed 9 months ago

dirkil commented 1 year ago

Is there an existing issue for this?

Product

Strawberry Shake

Describe the bug

I followed the instructions in "Get Started" for a console application but used a Hygraph (former known as GraphCMS) backend. Yesterday I struggled to run the init step which lead to this issue which has been resolved by using version 13.6.0-rc.0 of the Strawberry.Tools.

I added a simple graphql query (which works in the playground) and started the build process. This lead to the following error:

0>------- Started building project: StrawberryShakeDemo
dotnet --version
dotnet "C:\Users\Dirk.nuget\packages\strawberryshake.server\13.6.0\build\..\tools\net7\dotnet-graphql.dll" generate "C:\tmp\StrawberryShakeDemo\StrawberryShakeDemo" -o "C:\tmp\StrawberryShakeDemo\StrawberryShakeDemo\obj\Debug\net7.0\berry" -n StrawberryShakeDemo -a md5 -t
Generate C# Clients started.
Generate ProjektDemo started.
Generate ProjektDemo completed in 293 ms
0>EXEC: Error SCHEMA_INTERFACE_NO_IMPL : There is no object type implementing interface `Entity`.
0>StrawberryShake.Server.targets(79,5): Error MSB3073 : Der Befehl "dotnet "C:\Users\Dirk.nuget\packages\strawberryshake.server\13.6.0\build\..\tools\net7\dotnet-graphql.dll" generate "C:\tmp\StrawberryShakeDemo\StrawberryShakeDemo" -o "C:\tmp\StrawberryShakeDemo\StrawberryShakeDemo\obj\Debug\net7.0\berry" -n StrawberryShakeDemo -a md5 -t" wurde mit dem Code 1 beendet.
0>------- Finished building project: StrawberryShakeDemo. Succeeded: False. Errors: 2. Warnings: 0
Build completed in 00:00:01.656

If I do the same thing but use the ChilliCream backend then everything works. That's why I think it must have to do with the specific schema. Therefore I attached the schema.graphql file for you to inspect.

schema.zip schema.extensions.graphql.zip

Steps to reproduce

  1. dotnet new tool-manifest
  2. dotnet tool install StrawberryShake.Tools --local --version 13.6.0-rc.0
  3. Create new solution with a console application project
  4. dotnet add Demo package StrawberryShake.Server
  5. dotnet graphql init
  6. Create file GetProjekte.graphql with a valid query
  7. Compile the solution

Relevant log output

No response

Additional Context?

No response

Version

13.6.0

glen-84 commented 10 months ago

There is no object type implementing interface Entity.

This seems accurate. The schema includes an Entity interface, but no types implement this interface.

Is the Hygraph schema complete?

glen-84 commented 9 months ago

Closing, as no response has been received from the author.