Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates GraphQL SDL/string printing to stop escaping forward slashes (\/ → /) and regenerates affected schema/resource and snapshot files to match the new output.
Changes:
- Removed forward-slash escaping from the GraphQL syntax writer.
- Updated GraphQL schema/resource
.graphqlfiles to use unescaped/in descriptions/URLs. - Regenerated numerous snapshot files impacted by the serialization change (plus one website doc tweak).
Reviewed changes
Copilot reviewed 69 out of 69 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| website/src/blog/2021-03-31-chillicream-platform-11-1/2021-03-31-chillicream-platform-11-1.md | Removes escaped slashes in a URL in the blog table entry. |
| src/StrawberryShake/CodeGeneration/test/CodeGeneration.Tests/resources/GitHub.graphql | Updates schema descriptions to use / instead of \/. |
| src/StrawberryShake/CodeGeneration/test/CodeGeneration.CSharp.Tests/resources/Schema_Bug_2.graphql | Updates description strings to use / instead of \/. |
| src/StrawberryShake/CodeGeneration/test/CodeGeneration.CSharp.Tests/resources/PaymentSchema.graphql | Updates description strings and specifiedBy URLs to use unescaped /. |
| src/StrawberryShake/CodeGeneration/test/CodeGeneration.CSharp.Tests/resources/BridgeClientDemo.graphql | Updates localized description strings to use / instead of \/. |
| src/Nitro/CommandLine/src/CommandLine/schema.graphql | Updates specifiedBy URLs to use unescaped /. |
| src/HotChocolate/Utilities/test/Utilities.Introspection.Tests/snapshots/IntrospectionFormatterTests.DeserializeStarWarsIntrospectionResult.snap | Updates snapshot to reflect unescaped / in printed output. |
| src/HotChocolate/MongoDb/test/Types.MongoDb/snapshots/ObjectIdTypeTests.Should_MapObjectIdToScalar.snap | Updates snapshot specifiedBy URL to use unescaped /. |
| src/HotChocolate/MongoDb/test/Types.MongoDb/snapshots/BsonTypeTests.Output_Should_BindAllRuntimeTypes.graphql | Updates description and specifiedBy URL to use unescaped /. |
| src/HotChocolate/MongoDb/test/Data.MongoDb.Filters.Tests/snapshots/MongoDbFilterVisitorComparableTests.Create_Implicit_Operation_Normalized.graphql | Updates specifiedBy URLs to use unescaped /. |
| src/HotChocolate/MongoDb/test/Data.MongoDb.Filters.Tests/snapshots/MongoDbFilterVisitorComparableTests.Create_Implicit_Operation.graphql | Updates specifiedBy URLs to use unescaped /. |
| src/HotChocolate/Language/src/Language.SyntaxTree/Utilities/SyntaxWriterExtensions.cs | Stops escaping / when printing GraphQL string values. |
| src/HotChocolate/Data/test/Data.Filters.Tests/Types/snapshots/ComparableOperationInputTests.Create_Implicit_Operation_Normalized.graphql | Updates specifiedBy URLs to use unescaped /. |
| src/HotChocolate/Data/test/Data.Filters.Tests/Types/snapshots/ComparableOperationInputTests.Create_Implicit_Operation.graphql | Updates specifiedBy URLs to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/snapshots/CodeFirstTests.Change_DefaultBinding_For_DateTime.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Types/Scalars/snapshots/LocalDateTypeTests.DateOnly_As_ReturnValue_Schema.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Types/Scalars/snapshots/LocalDateTypeTests.DateOnly_As_Argument_Schema.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Types/Scalars/snapshots/LocalDateTimeTypeTests.LocalDateTime_As_ReturnValue_Schema.snap | Updates description to use / instead of \/. |
| src/HotChocolate/Core/test/Types.Tests/Types/Scalars/snapshots/LocalDateTimeTypeTests.LocalDateTime_As_Argument_Schema.snap | Updates description to use / instead of \/. |
| src/HotChocolate/Core/test/Types.Tests/Types/Relay/snapshots/IdAttributeTests.Id_Type_Is_Correctly_Inferred.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Types/Directives/snapshots/SpecifiedByDirectiveTypeTests.EnsureSpecifiedByDirectiveExistsInSdl.graphql | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Types/Directives/SpecifiedByDirectiveTypeTests.cs | Updates inline snapshot string to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Configuration/snapshots/TypeTrimmerTests.Executable_Directives_Should_Be_Visited.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Configuration/snapshots/TypeDiscoveryTests.TypeDiscovery_Should_InferStructs.snap | Updates specifiedBy URLs to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Configuration/snapshots/TypeDiscoveryTests.InferDateTimeFromModel.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Tests/Configuration/snapshots/TypeDiscoveryTests.InferDateTime.snap | Updates specifiedBy URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Scalars.Tests/snapshots/RgbaTypeTests.Schema_WithScalar_IsMatch.snap | Updates description URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Scalars.Tests/snapshots/RgbTypeTests.Schema_WithScalar_IsMatch.snap | Updates description URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Scalars.Tests/snapshots/IsbnTypeTests.Schema_WithScalar_IsMatch.snap | Updates description URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Scalars.Tests/snapshots/HslaTypeTests.Schema_WithScalar_IsMatch.snap | Updates description URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Scalars.Tests/snapshots/HslTypeTests.Schema_WithScalar_IsMatch.snap | Updates description URL to use unescaped /. |
| src/HotChocolate/Core/test/Types.Scalars.Tests/snapshots/EmailAddressTypeTests.Schema_WithScalar_IsMatch.snap | Updates description URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/snapshots/BuiltInTypesShareableTests.Ensure_PagingInfo_Is_Shareable_When_Shareable_Already_Registered.graphql | Updates federation link URL and description to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/snapshots/BuiltInTypesShareableTests.Ensure_PagingInfo_Is_Shareable.graphql | Updates federation link URL and description to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/ServiceTypeTests.cs | Updates inline snapshot federation link URLs to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/RequiresScopesDirectiveTests.RequiresScopesDirectives_GetAddedCorrectly_CodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/RequiresScopesDirectiveTests.RequiresScopesDirectives_GetAddedCorrectly_Annotations.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/RequiresScopesDirectiveTests.RequiresScopesDirective_GetsAddedCorrectly_Annotations.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/RequiresDirectiveTests.AnnotateProvidesToFieldCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/RequiresDirectiveTests.AnnotateProvidesToClassAttributePureCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/ProvidesDirectiveTests.AnnotateProvidesToFieldCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/ProvidesDirectiveTests.AnnotateProvidesToClassAttributePureCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/PolicyDirectiveTests.PolicyDirectives_GetAddedCorrectly_CodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/PolicyDirectiveTests.PolicyDirectives_GetAddedCorrectly_Annotations.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/PolicyDirectiveTests.PolicyDirective_GetsAddedCorrectly_Annotations.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/OverrideDirectiveTests.OverrideDirective_Progressive_Annotation.snap | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/OverrideDirectiveTests.OverrideDirective_Annotation.snap | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/NonResolvableKeyDirectiveTests.AnnotateKeyToObjectTypeCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/NonResolvableKeyDirectiveTests.AnnotateKeyToObjectTypeAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/NonResolvableKeyDirectiveTests.AnnotateKeyToInterfaceTypeCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/NonResolvableKeyDirectiveTests.AnnotateKeyToInterfaceAttributesAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/NonResolvableKeyDirectiveTests.AnnotateKeyToClassAttributesAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/NonResolvableKeyDirectiveTests.AnnotateKeyToClassAttributeAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/KeyDirectiveTests.AnnotateKeyToObjectTypeCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/KeyDirectiveTests.AnnotateKeyToObjectTypeAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/KeyDirectiveTests.AnnotateKeyToInterfaceTypeCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/KeyDirectiveTests.AnnotateKeyToInterfaceAttributesAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/KeyDirectiveTests.AnnotateKeyToClassAttributesAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/KeyDirectiveTests.AnnotateKeyToClassAttributeAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/ExternalDirectiveTests.AnnotateExternalToTypeFieldCodeFirst.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/ExternalDirectiveTests.AnnotateExternalToTypeFieldAnnotationBased.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/ComposeDirectiveTests.ExportDirectiveUsingTypeCodeFirst.graphql | Updates composed directive link URLs to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/Directives/snapshots/ComposeDirectiveTests.ExportDirectiveUsingNameCodeFirst.graphql | Updates composed directive link URLs to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/CertificationSchema/CodeFirst/snapshots/CertificationTests.Subgraph_SDL.snap | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/CertificationSchema/CodeFirst/snapshots/CertificationTests.Schema_Snapshot.snap | Removes redundant .snap schema snapshot file. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/CertificationSchema/CodeFirst/snapshots/CertificationTests.Schema_Snapshot.graphql | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/CertificationSchema/AnnotationBased/snapshots/CertificationTests.Subgraph_SDL.snap | Updates federation link URL to use unescaped /. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/CertificationSchema/AnnotationBased/snapshots/CertificationTests.Schema_Snapshot.snap | Removes redundant .snap schema snapshot file. |
| src/HotChocolate/ApolloFederation/test/ApolloFederation.Tests/CertificationSchema/AnnotationBased/snapshots/CertificationTests.Schema_Snapshot.graphql | Updates federation link URL to use unescaped /. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| WriteEscapeCharacterHelper(writer, '\\'); | ||
| break; | ||
|
|
||
| case '/': | ||
| WriteEscapeCharacterHelper(writer, '/'); | ||
| break; | ||
|
|
||
| case '\b': | ||
| WriteEscapeCharacterHelper(writer, 'b'); | ||
| break; |
There was a problem hiding this comment.
In WriteEscapeCharacter, the escape logic currently only handles a few named escapes (e.g. \n, \r, \t). With this method being touched, consider also escaping all other non-printable control characters (U+0000–U+001F and U+007F–U+009F) as unicode escapes (e.g. \uXXXX), per the GraphQL spec guidance quoted in the PR description, to avoid emitting invalid SDL/query text when such characters appear in string values/descriptions.
🚀 Fusion Gateway Performance ResultsSimple Composite QueryConstant Load (50 VUs)
📊 Response Time Metrics
Ramping Load (0→50→500→50 VUs)
📊 Response Time Metrics
Executed Query fragment User on User {
id
username
name
}
fragment Review on Review {
id
body
}
fragment Product on Product {
inStock
name
price
shippingEstimate
upc
weight
}
query TestQuery {
topProducts(first: 5) {
...Product
reviews {
...Review
author {
...User
}
}
}
}Deep Recursion QueryConstant Load (50 VUs)
📊 Response Time Metrics
Ramping Load (0→50→500→50 VUs)
📊 Response Time Metrics
Executed Query fragment User on User {
id
username
name
}
fragment Review on Review {
id
body
}
fragment Product on Product {
inStock
name
price
shippingEstimate
upc
weight
}
query TestQuery {
users {
...User
reviews {
...Review
product {
...Product
reviews {
...Review
author {
...User
reviews {
...Review
product {
...Product
}
}
}
}
}
}
}
topProducts(first: 5) {
...Product
reviews {
...Review
author {
...User
reviews {
...Review
product {
...Product
}
}
}
}
}
}Variable Batching ThroughputConstant Load (50 VUs)
📊 Response Time Metrics
Ramping Load (0→50→500→50 VUs)
📊 Response Time Metrics
Executed Query query TestQuery_8f7a46ce_2(
$__fusion_1_upc: ID!
$__fusion_2_price: Long!
$__fusion_2_weight: Long!
) {
productByUpc(upc: $__fusion_1_upc) {
inStock
shippingEstimate(weight: $__fusion_2_weight, price: $__fusion_2_price)
}
}Variables (5 sets batched in single request) [
{ "__fusion_1_upc": "1", "__fusion_2_price": 899, "__fusion_2_weight": 100 },
{ "__fusion_1_upc": "2", "__fusion_2_price": 1299, "__fusion_2_weight": 1000 },
{ "__fusion_1_upc": "3", "__fusion_2_price": 15, "__fusion_2_weight": 20 },
{ "__fusion_1_upc": "4", "__fusion_2_price": 499, "__fusion_2_weight": 100 },
{ "__fusion_1_upc": "5", "__fusion_2_price": 1299, "__fusion_2_weight": 1000 }
]No baseline data available for comparison. Run 21820804834 • Commit 7c6b32b • Mon, 09 Feb 2026 10:27:05 GMT |
Summary of the changes (Less than 80 chars)
It's not necessary according to the spec: