ghostdogpr / caliban

Functional GraphQL library for Scala

Home Page:https://ghostdogpr.github.io/caliban/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Interfaces are not rendered properly when renamed via `.rename`

kyri-petrou opened this issue · comments

Repro: https://scastie.scala-lang.org/YCmCwByRQIqhfoNnyySVrQ

Note that it works as expected if the interface is renamed via the @GQLName annotation

Current output:

schema {
  query: Queries
}

union ASTValue = ASTValueBoolean | ASTValueList

interface ASTParameter

interface Parameter

type ASTValueBoolean implements Parameter {
  value: Boolean!
}

type ASTValueList implements Parameter {
  values: [ASTValue!]!
}

type ASTVariable implements Parameter {
  name: String!
}

type Queries {
  param: ASTParameter!
}

Expected:

schema {
  query: Queries
}

union ASTValue = ASTValueBoolean | ASTValueList

interface ASTParameter

type ASTValueBoolean implements ASTParameter {
  value: Boolean!
}

type ASTValueList implements ASTParameter {
  values: [ASTValue!]!
}

type ASTVariable implements ASTParameter {
  name: String!
}

type Queries {
  param: ASTParameter!
}