OpenAPITools / OpenAPITools/openapi-generator

Loss of opaque names for simple types

Open
#1,590 4 comments 1 reaction 1 assignee View on GitHub

@bjgill is already working on this.

Since Dec 17, 2018.

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

Description

Description

I am trying to wrap a primitive type such as a string with an opaqueWrapper. This is correctly rendered using swagger, but OpenAPI 'sees through' the wrapper and the underlying primitive type appears in the method signatures of the resulting generated code.

openapi-generator version

current master

OpenAPI declaration file content or url
definitions:
  request:
    type: object
    required:
      - opaque
    properties:
      opaque:
        $ref: '#/definitions/opaqueWrapper'

opaqueWrapper:
  type : string
  description: A string in an opaque format.
Command line used for generation
Steps to reproduce
Related issues/PRs
Suggest a fix/enhancement

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.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.