OpenAPITools / OpenAPITools/openapi-generator

[BUG] Regression on JSonSubType.Type naming due to PR #536

Open
#1,925 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Issue: Bug
Dominant language
Java
Stars
26.8k
Forks
7.7k
PR merge metrics
PR metrics pending

Description

The issue was fixed in swagger codegen here but has been reintroduce with commit 0a52f56ba42853d18896820d4e9eb560e05bb1e9 in PR #536

The problem is that the name of the type in JSonSubType.Type annotation doesn't include the suffix or preffix when used with modelNamePrefix or modelNameSuffix option.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Compare the regression introduced by commit 0a52f56ba42853d18896820d4e9eb560e05bb1e9 in PR #536 with the earlier swagger-codegen fix in PR #5736. Reproduce generation with modelNamePrefix and modelNameSuffix, then verify that JSonSubType.Type includes the configured prefix or suffix and add coverage for the regression.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.