Skip to content

Generated models resolve to object and do not include children. Some are incorrect. #142

@EdCharbeneau

Description

@EdCharbeneau

/// <summary>The API representation of a Knowledge Box object.</summary>
/// <param name="Slug">Slug</param>
/// <param name="Uuid">Uuid</param>
/// <param name="Config">Config</param>
/// <param name="Model">Model</param>
public record KnowledgeBoxObj(object Slug, string Uuid, object Config, object Model);

KnowledgeBoxObj:
properties:
slug:
anyOf:
- type: string
maxLength: 250
minLength: 1
pattern: ^[a-zA-Z0-9:_-]+$
- type: 'null'
title: Slug
uuid:
type: string
title: Uuid
config:
anyOf:
- $ref: '#/components/schemas/KnowledgeBoxConfig'
- type: 'null'
model:
anyOf:
- $ref: '#/components/schemas/SemanticModelMetadata'
- type: 'null'

The generator appears to stop at the top level of a hierarchy and resolve to object rather than the class it should represent.

In the example, all properties are simple object when they should be other types.

public record KnowledgeBoxObj(object Slug, string Uuid, object Config, object Model);

Should be:

public record KnowledgeBoxObj(string Slug, string Uuid, KnowledgeBoxConfig Config, SemanticModelMetadata Model);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions