[BUG] Java generator "spring-boot" for server side stubs incompatible with Maven 3.10
Los mantenedores suelen responder en 1 día
@Karan-Rastogi ya está trabajando en esto.
Desde el 9/10/2026.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 72/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- java, spring-boot
- Área
- build-system
Línea de trabajo
La dependencia duplicada proviene de la plantilla de soporte pom.xml generada para la biblioteca spring-boot, así que empieza buscando spring-boot-starter-restclient en los recursos del generador spring-boot de Java. Confirma que aparece tanto en el alcance compile como en el alcance test y luego elimina la copia con alcance test. Está terminado cuando el pom.xml generado la declara una sola vez y el proyecto generado se compila con Maven 3.10 usando mvn clean package.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
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
Yesterday our pipelines using openapi generator CLI via docker images started failing. It turned out the underlying agents where updated to using Maven 3.10 (previously 3.9).
That change in Maven now treats certain duplicated dependencies in the POM as an error instead of just a warning being logged.
The error is related to org.springframework.boot:spring-boot-starter-restclient being duplicated in the Maven pom.xml compile and test scope. As needed for compile there is no need to redeclare for test also.
openapi-generator version
v7.26.0- no regression I'd say
OpenAPI declaration file content or url
not related to the OpenAPI schema itself, the respective generated Maven POM (support file?) is erronuous
Generation Details
- using
openapitools/openapi-generator-clifrom Docker distribution - using the following
config.yaml
artifactId: "whatever-server"
groupId: "my.org.system"
apiPackage: "my.org.system.whatever.server"
modelPackage: "my.org.system.whatever.server.model"
configPackage: "my.org.system.whatever.server"
library: "spring-boot"
artifactVersion: "0.0.10-20261009.t064033"
openApiNullable: "false"
modelPropertyNaming: "camelCase"
useSpringBoot4: "True"
useJackson3: "True"
useJakartaEe: "false"
interfaceOnly: "true"
delegatePattern: "false"
useResponseEntity: "false"
useBeanValidation: "true"
skipDefaultInterface: "true"
generateBuilders: "true"
generateApiTests: "false"
generateModelTests: "false"
Steps to reproduce
Just use the spring-boot Java generator and try to mvn clean package the outcome.
You will encounter a maven build error stating that spring-boot-starter-restclient is duplicated.
[ERROR] 'dependencies.dependency.(groupId:artifactId:type:classifier)' must be unique: org.springframework.boot:spring-boot-starter-restclient:jar -> duplicate declaration of version (?) @ line 78, column 21
Related issues/PRs
none identified so far
Suggest a fix
It could be as easy as just fixing the respective pom.xml mustache template and remove the duplicated spring-boot-starter-restclient from the test scoped dependencies, as it is compile scope already and does not need to be repeated.
- Lenguaje dominante
- Java
- Estrellas
- 26.8k
- Forks
- 7.7k
- Merge medio
- 1 d 15 h
- PR fusionados (30 d)
- 158
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de OpenAPITools/openapi-generator
-
[BUG][RUST] chrono date-time path/query/header params are not serialized as RFC 3339Posiblemente ocupada @teovillanueva la tomó hace 3 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
OpenAPITools/openapi-generator#25297 ·
Los mantenedores suelen responder en 1 día
-
[BUG][RUST] Reqwest - encoding of spaces in path parametersPosiblemente ocupada @GlenWright la tomó hace 6 días. AbiertoIssue: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
OpenAPITools/openapi-generator#25257 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
OpenAPITools/openapi-generator#25237 ·
Los mantenedores suelen responder en 1 día
-
[BUG] OpenApiEvaluator reports "default value not in enum" for numerically equal values with different scale (e.g. 1.5 and 1.50)Posiblemente ocupada @mohitduhan19 la tomó hace 8 días. AbiertoIssue: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
OpenAPITools/openapi-generator#25233 ·
Los mantenedores suelen responder en 1 día
-
[BUG] OpenApiEvaluator emits "Unused model" warnings even when recommendations are disabledPosiblemente ocupada @mohitduhan19 la tomó hace 8 días. AbiertoIssue: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
OpenAPITools/openapi-generator#25232 ·
Los mantenedores suelen responder en 1 día
Todos los issues de OpenAPITools/openapi-generator
Issues similares
-
area: android good first issue help wanted testing
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
Gautam-aman/ResQNet#56 ·
Los mantenedores suelen responder en 1 día
-
documentation hermes-queue
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
chrisalunlloyd2-sudo/mindpalace#294 ·
Los mantenedores suelen responder en 1 día
-
better night vision compatAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
QuicksilverMC/Argentum#31 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
saysky/ForestBlog#111 ·
-
hawkbit-dmf-server 1.1.0 does not start: NoClassDefFoundError jakarta/servlet/ServletResponseAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
eclipse-hawkbit/hawkbit#3429 · 1 comentario ·
Los mantenedores suelen responder en 1 día