Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Two default constructors incorrectly added when types are parcelable and includeConstructors is active #742

Closed
locofrank opened this issue Jun 12, 2017 · 6 comments
Milestone

Comments

@locofrank
Copy link

The latest build was generating 2 constructors for several of my classes

I needed to roll back to 0.4.35 to fix my project

@joelittlejohn
Copy link
Owner

Are you using Parcelable classes by any chance?

@joelittlejohn
Copy link
Owner

And are the constructors duplicates? Do the classes compile? It would be useful to have some more detail here. Thanks!

@yomik
Copy link
Contributor

yomik commented Jun 13, 2017

Oh, I think I'm the one to blame for that.
I reproduced this by setting the includeConstructors = true in the configuration. I overlooked that one.
I'm going to provide a fix for this, but now I wonder what other settings might affect the changes....
For instance, the code refers to isConstructorsRequiredPropertiesOnly, which is not in the documentation (some configuration that was added recently ?).

Anyway, I'm trying to fix this ASAP, and try to see what other side effects might come from other settings as well.

Sorry for the trouble

yomik added a commit to yomik/jsonschema2pojo that referenced this issue Jun 13, 2017
joelittlejohn added a commit that referenced this issue Jun 13, 2017
Fix for #742 : Generating 2 constructors
@joelittlejohn
Copy link
Owner

Thanks for reporting this quickly @locofrank. Closed by #743.

@joelittlejohn
Copy link
Owner

I'll release 0.4.37 shortly.

@joelittlejohn joelittlejohn changed the title Generating 2 constructors Two default constructors incorrectly added when types are parcelable and includeConstructors is active Jun 13, 2017
@joelittlejohn joelittlejohn added this to the 0.4.37 milestone Jun 13, 2017
@locofrank
Copy link
Author

Wow! You folks are on top of it. Sorry I didn't respond quickly. Thanks for the quick fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants