Describe the bug
#4027 introduced an unannounced breaking change in 25.0. Quite a few places that now contain a DirectivesHolder implicitly call toString on it in their own toString implementations. Before this change that worked just fine, because directives were just a list and lists tend to have reasonable toString implementations.
Here is one example:
|
public String toString() { |
|
return "ScalarTypeDefinition{" + |
|
"name='" + name + '\'' + |
|
", directives=" + directives + |
|
'}'; |
|
} |
DirectivesHolder, however, does not have one, so all those other toString implementations no longer produce reasonable output.
To Reproduce
Create a ScalarTypeDefinition object. Call toString on it.
Actual output:
ScalarTypeDefinition{name='Int', directives=graphql.language.NodeUtil$DirectivesHolder@5c995dee}
Expected output (and actual output in 24.x):
ScalarTypeDefinition{name='Int', directives=[]}
Describe the bug
#4027 introduced an unannounced breaking change in 25.0. Quite a few places that now contain a DirectivesHolder implicitly call
toStringon it in their owntoStringimplementations. Before this change that worked just fine, because directives were just a list and lists tend to have reasonabletoStringimplementations.Here is one example:
graphql-java/src/main/java/graphql/language/ScalarTypeDefinition.java
Lines 116 to 121 in 021fe1b
DirectivesHolder, however, does not have one, so all those othertoStringimplementations no longer produce reasonable output.To Reproduce
Create a ScalarTypeDefinition object. Call
toStringon it.Actual output:
Expected output (and actual output in 24.x):