Fixed
Status Update
Comments
je...@google.com <je...@google.com>
lu...@google.com <lu...@google.com> #2
Issue is caused by recent changes to the Variant API, which restricted buildConfigField values to specific types (not including types such as floats and java.util.OptionalInt). A fix for this which allows any type to be used will be merged shortly.
Description
With AGP up until 4.1.0-alpha09 you could have this in your defaultConfig block:
This builds correctly, and in BuildConfig you'll see these fields:
However, in 4.1.0-dev this no longer works; the build aborts with
Unsupported BuildConfig type : float
orUnsupported BuildConfig type : java.util.OptionalInt
depending on the order.(These things were actively used; for example, this is why iosched no longer builds/syncs with 4.1.0-dev; see line 41 for a float and 37 for fully-qualified-name class usages of this here:https://github.com/google/iosched/blob/master/mobile/build.gradle#L37 )