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

2.10 introduces another binary compatibility issue in KotlinModule constructor #279

Closed
kilink opened this issue Dec 12, 2019 · 3 comments
Closed
Milestone

Comments

@kilink
Copy link

kilink commented Dec 12, 2019

This is essentially the same issue as in #178, but again there is a binary compatibility issue. For instance, code that instantiates KotlinModule and was compiled against 2.9.10 will break if 2.10.1 is used at runtime. This time it's due to the introduction of the nullisSameAsDefault parameter.

As was mentioned in the other issue, backwards compatibility can be restored by re-introducing a constructor with the old signature.

I would again urge using something like japicmp to ensure this doesn't happen going forward.

@cowtowncoder
Copy link
Member

Thank you for reporting this. I wish I had noticed this when PR was submitted; it is obvious in hindsight and I usually notice these on Java changes and ask for addition (or add myself) deprecated variants.
But will keep closer eye in future.

Addition of tooling for checking signature changes is worth consideration; the main challenge from the past was the noisiness of tools -- perhaps this would less of a problem with Kotlin, esp. since module codebase is quite small.
As long as it would be possible to annotate acceptable changes after review (that is, breaking build is fine, for initial change, but there needs to be possibility of manual override for some specific cases deemed necessary, esp. for minor version upgrades) that seems like something that would be very useful.

cowtowncoder added a commit that referenced this issue Dec 30, 2019
@cowtowncoder
Copy link
Member

Fixed.

@cowtowncoder
Copy link
Member

2.10.2 now released.

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

2 participants