You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
versioin 8.1 generates against openapi-generator-maven-plugin 7.8.0:
// This file is generated by https://github.com/dart-ogurets/dart-openapi-maven - you should not modify it// log generation bugs on Github, as part of the license, you must not remove these headers from the Mustache templates.// this project is maintained as part of FeatureHub - please consider sponsoring us at https://github.com/featurehub-io// BusinessclassBusiness {
String id;
String businessName;
String vatNumber;
String companyNumber;
Address headOfficeAddress;
String logoUrl;
// id required: true nullable: false default: inherited: false container false// businessName required: true nullable: false default: inherited: false container false// vatNumber required: true nullable: false default: inherited: false container false// companyNumber required: true nullable: false default: inherited: false container false// headOfficeAddress required: true nullable: false default: inherited: false container false// logoUrl required: true nullable: false default: inherited: false container falseBusiness(
{
requiredthis.id
,
requiredthis.businessName
,
requiredthis.vatNumber
,
requiredthis.companyNumber
,
requiredthis.headOfficeAddress
,
requiredthis.logoUrl
}
)
Whereas version 7.2 against openapi-generator-maven-plugin 7.8.0:
// This file is generated by https://github.com/dart-ogurets/dart-openapi-maven - you should not modify it// log generation bugs on Github, as part of the license, you must not remove these headers from the Mustache templates.// this project is maintained as part of FeatureHub - please consider sponsoring us at https://github.com/featurehub-io// BusinessclassBusiness {
String? id;
String businessName;
String? vatNumber;
String? companyNumber;
Address? headOfficeAddress;
String? logoUrl;
Business(
{
this.id
,
requiredthis.businessName
,
this.vatNumber
,
this.companyNumber
,
this.headOfficeAddress
,
this.logoUrl
}
);
Versions
We only support bug fixes on the latest version of this plugin, please
confirm which version you are using?
openapi-dart-generator 8.1
openapi-generator-maven-plugin 7.8.0,
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
This is deliberate (and in the README). The default nullability for openApi fields is nullable: false - so the new version reflects the correct definition as specified in the API document. required reflects serialization not nullability. I would recommend you make the fields nullable or give them a default value.
Describe the bug
When using 8.1 against openapi-generator-maven-plugin 7.8.0, all parameters of an object are generated as required.
Expected behavior
When an object has say one required parameter, all parameters are generated as required, not just the one defined in the swagger
To Reproduce
versioin 8.1 generates against openapi-generator-maven-plugin 7.8.0:
Whereas version 7.2 against openapi-generator-maven-plugin 7.8.0:
Versions
We only support bug fixes on the latest version of this plugin, please
confirm which version you are using?
openapi-dart-generator 8.1
openapi-generator-maven-plugin 7.8.0,
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: