Android Contacts API Library written in Kotlin with Java interoperability. No more ContentProviders and cursors. Say goodbye to ContactsContract. Build your own contacts app!
v0.4.0 - New APIs, a minor bugfix, and some deprecations plus a breaking change due to big build/dependency updates - contacts-android Release Notes | AnnounceHQ
v0.4.0 - New APIs, a minor bugfix, and some deprecations plus a breaking change due to big build/dependency updates
It's been almost a year since the last release. How time flies when life and work gets busy π I'm super hyped to have found some time to get some work done on this precious library π₯
The main intent with this release was to get the build and dependencies up-to-date so this library does not get left behind in the dust with the fast pace of tech. We are now once again using the cutting-edge versions of AGP, KGP, Gradle, target/compileSdk, coroutines, tedpermissions, mkdocs, and mkdocs material π
Aside from that, there's some new features, a minor bugfix, and deprecations and breaking changes that resulted from the big build/dep updates.
β οΈ Proper semantic versioning is not being followed prior to version 1.0.0. This means that . More context in https://github.com/vestrel00/contacts-android/discussions/284#discussioncomment-11923170
minor version bumps may contain breaking changes
π‘ New features & improvements
Dedicated API for querying contacts using lookup keys #364, documentation
Allow overriding common (builtin) data kinds via custom data integration #344, documentation
Support multiple Notes per RawContact #343, documentation
π Bug fixes
ContactRefresh util may return null if local contact lookup key changes due to primary display name source update #365
ποΈ Deprecations
Deprecate Im entity, fields, and related functions (deprecated in Android API 35) #361
Deprecate SipAddress entity, fields, and related functions (deprecated in Android API 35) #362
π£ Breaking changes
API's data class' 'copy' methods no longer have public visibility #358
β»οΈ Build/Dependency updates
December 2024 Build & Dependency Updates #356
AGP 8.7.3
KGP 2.1.0
Gradle 8.9
target/compileSdk 35
coroutines 1.10.1
tedpermissions 3.4.2
π§ Migrating from 0.3.2 -> 0.4.0
API's data class' 'copy' methods no longer have public visibility #358
You should not be affected by this, at least that is my hope π€
However, for those of you that have been using the copy method of some data classes such as Contact, MutableContact, RawContact, MutableRawContact, Address, MutableAddress, Email, MutableEmail, Phone, MutablePhone, etc... you will no longer be allowed to do that π
There is no actual "migration guide". You simply cannot do it anymore. The API has always been designed for this to be the case. Vandolf apologizes if this was not made clear anywhere π. It was simply not strictly enforceable at the language level prior to Kotlin version 2. If you want more context, read the Side note section of #358 π
It is recommended to rethink your approach to using this API. You should not need to or be doing it (using copy method).
If you believe that the API should provide a copy method for certain data classes with internal constructors, feel free to start a discussion.