Skip to content

[BUG][GRADLE] When the open-api-specification is changed for the schemas referred via $ref, gradle task "GenerateTask" does not detect the changes. #16723

@DeepikaSridhar2112

Description

@DeepikaSridhar2112

Issue Description:
When changes are made to open-api-schemas referred via the $ref keyword, gradle is unable to detect the changes made to the schema.
However,gradle is able to detect changes for schema changes provided directly in openapi.yml .

Link to a sample project which recreates the issue can be found at
https://github.com/DeepikaSridhar2112/open-api-issue

Versions used:
openapi-generator
7.0.1
Gradle
7.5.1

Steps to reproduce:
https://github.com/DeepikaSridhar2112/open-api-issue contains sampler project to recreate the issue. In the sample, schema is being defined via searchResults.yml.When changes are made to searchResult.yml
and openApiGenerate task is invoked, the generated code doesnt reflect the schema changes

Suggested fix:
The openApiTask is unaware of the schema location,. Adding it as an input argument in GenerateTask fixes this refresh issue.

Link to the PR to fix the issue #16735

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions