Harden OpenAPI/GraphQL parsing and code generation#2
Merged
Conversation
Handle dotted schema names, array component schemas, inline enums, duplicate operation names, type/namespace collisions, and non-fatal parse errors. Add GraphQLNamespaces.sbn template, SimplifySchemaName and StripHttpVerbPrefix helpers, and description sanitization. Generate fully-qualified type refs when names collide with namespace segments.
Operations with no input parameters now generate a dedicated empty record (e.g. public record GetHealthInput;) instead of using LanguageExt.Unit. This gives each train a unique input type for mediator routing and avoids HotChocolate InputObjectType issues.
Directory.GetFiles ordering varies between Debug/Release builds. Filter out I*Train.cs interface files to consistently get the implementation file which contains the Description attribute.
|
This PR is included in version 1.2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Namespace.Type), array component schemas, inline enums, and inline object arrays in OpenAPI parsingGraphQLNamespaces.sbntemplate for generating namespace constants,SimplifySchemaName/StripHttpVerbPrefixhelpers, and description sanitization for multiline/escaped stringsobjectto avoid HotChocolate zero-field type errorsTest plan