What are the versions of any relevant development tools you are using?
Report
What unexpected behavior are you seeing?
Creating the AirshipConfigOptions with .setEnabledFeatures() without providing any features to enable, throws an exception in airships PrivacyManager when it tries to combine all features.
I believe this started after PrivacyManager was converted to kotlin as the previous versions with the java implementation did not crash.
What is the expected behavior?
It doesn't throw an exception.
What are the steps to reproduce the unexpected behavior?
Initialise Airship with
AirshipConfigOptions.Builder()
.setEnabledFeatures()
// other options omitted as they are not relevant
.build()
Do you have logging for the issue?
java. lang UnsupportedOperationException: Empty collection can't be reduced. at
com.urbanairship.PrivacyManager$Feature.combining$urbanairship_core_release(PrivacyManager.kt:526) at
com.urbanairship.PrivacyManager$Feature$Companion.combined(PrivacyManager.kt:487) at
com.urbanairship.PrivacyManager$Feature.combined(Unknown Source:2) at
com.urbanairship.AirshipConfigOptions$Builder.setEnabledFeatures(AirshipConfigOptions.java:1614)
Thanks for the report, we will get a release out ASAP with the fix. For now you can use .setEnabledFeatures(PrivacyManager.Feature.NONE) as a workaround.
Preliminary Info
What Airship dependencies are you using?
What are the versions of any relevant development tools you are using?
Report
What unexpected behavior are you seeing?
Creating the
AirshipConfigOptions
with.setEnabledFeatures()
without providing any features to enable, throws an exception in airshipsPrivacyManager
when it tries to combine all features.We're getting a
UnsupportedOperationException
with the messageEmpty collection can't be reduced
from here: https://github.com/urbanairship/android-library/blob/main/urbanairship-core/src/main/java/com/urbanairship/PrivacyManager.kt#L298-L301I believe this started after
PrivacyManager
was converted to kotlin as the previous versions with the java implementation did not crash.What is the expected behavior?
It doesn't throw an exception.
What are the steps to reproduce the unexpected behavior?
Initialise Airship with
Do you have logging for the issue?