Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Source code generation fails under 1.0.0-M1 #2017

Open
aoiroaoino opened this issue Sep 5, 2024 · 1 comment
Open

Source code generation fails under 1.0.0-M1 #2017

aoiroaoino opened this issue Sep 5, 2024 · 1 comment

Comments

@aoiroaoino
Copy link

Thank you for providing such a great tool! I also use it for my work. :)

When running under the following conditions, an error occurs, and the source code generation fails:

  • Version: 1.0.0-M1
  • Scala Version: 2.12.18 (intended for use with sbt-guardrail)
  • JDK: Corretto-17.0.11.9.1

(I have masked the type names.)

    FooBarType:
      type: string
      enum:
        - A
        - B
        - C
        - D
    foo_type:
      type: array
      nullable: false
      items:
        allOf:
          - $ref: '#/components/schemas/FooBarType'
sbt:my-project> guardrail
Error:Unknown type for the following structure (No type definition, class: io.swagger.v3.oas.models.media.ComposedSchema, .components.schemas.foo_type.items):
  Tracker(class ComposedSchema {
      class Schema {
      }
  }, Vector(.components, .schemas, .foo_type, .items))

[error] (Compile / guardrail) dev.guardrail.sbt.CodegenFailedException
[error] Total time: 1 s, completed 2024/09/05 16:20:55

Here is the code to reproduce the issue:
aoiroaoino@199dc9f

Could you please take a look? Thank you for your assistance.

@blast-hardcheese
Copy link
Member

Thank you for the reproducing test case! Please pardon the delay in response, looking now. I'll follow up

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants