-
-
Notifications
You must be signed in to change notification settings - Fork 7.3k
Open
Labels
Description
Bug Report Checklist
- Have you provided a full/minimal spec to reproduce the issue?
- Have you validated the input using an OpenAPI validator?
- Have you tested with the latest master to confirm the issue still exists?
- Have you searched for related issues/PRs?
- What's the actual output vs expected output?
- [Optional] Sponsorship to speed up the bug fix or feature request (example)
Description
This:
paths:
/endpoint:
post:
tags:
- "My \"quoted\" api"Generates:
...
tags = { "My "quoted" api" }
...
Other inputs with similar results:
My \"quoted\" api'My "quoted" api''My \"quoted\" api'
Generated code:
@Tag(name="My "quoted" api")@Operation(tags={ "My \"quoted\" api" })
Expected generated string: "My \"quoted\" api"
Description/comment strings are correctly escaped, and are not affected.
openapi-generator version
7.12.0, 7.13.0, 7.18.0 are affected.
7.12.0 works as expected does not include the example objects in the generated interface, and therefore did not cause issues.
OpenAPI declaration file content or url
openapi: 3.0.1
info:
title: Example
version: 0.1.0
paths:
/endpoint:
get:
tags:
- Example "quoted" ops
summary: Summary
responses:
200:
description: Success
content:
application/json:
schema:
type: object
examples:
Example1:
value:
res: a "quoted" string
Generation Details
Stack: Maven, Spring Boot, openapi-generator-maven-plugin
Configuration:
<minimalUpdate>true</minimalUpdate>
<configOptions>
<useSpringBoot3>true</useSpringBoot3>
<oas3>true</oas3>
<useSpringController>true</useSpringController>
<useSpringfox>false</useSpringfox>
<interfaceOnly>true</interfaceOnly>
</configOptions>