Fixed
Status Update
Comments
vi...@google.com <vi...@google.com>
bo...@google.com <bo...@google.com>
wd...@google.com <wd...@google.com>
wd...@google.com <wd...@google.com>
bi...@gmail.com <bi...@gmail.com> #2
Thank you for this feedback. The team may reach out for more information on triaging or reproducing this issue.
se...@gmail.com <se...@gmail.com> #3
I have tried the example project you've provided, it does not reproduce.
Could you please try running with -Pandroid.useDexArchive=false? This disables the new dexing pipeline, and fallbacks to the old one.
Could you please try running with -Pandroid.useDexArchive=false? This disables the new dexing pipeline, and fallbacks to the old one.
dt...@gmail.com <dt...@gmail.com> #4
@Mario Did you get a chance to try the build with -Pandroid.useDexArchive=false flag?
[Deleted User] <[Deleted User]> #5
I'm the college of @Mario and I make it work without issues and without using -Pandroid.useDexArchive=false by using alpha6 and removing retrolambda
ta...@gmail.com <ta...@gmail.com> #6
Sorry my comment from Apr 21, 2017 12:41PM was wrong.
With -Pandroid.useDexArchive=false it looks like this
:app:transformClassesWithDesugarForNonpayItalyCompatDebugAndroidTest
:app:transformClassesWithPreDexForNonpayItalyCompatDebugAndroidTest
Dex: warning: Ignoring InnerClasses attribute for an anonymous inner class
(org.ccil.cowan.tagsoup.Parser$1) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
solution is to recompile the class from source, using an up-to-date compiler
and without specifying any "-target" type options. The consequence of ignoring
this warning is that reflective operations on this class will incorrectly
indicate that it is *not* an inner class.
:app:transformDexWithDexForNonpayItalyCompatDebugAndroidTest FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformDexWithDexForNonpayItalyCompatDebugAndroidTest'.
> com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: com.android.dex.DexIndexOverflowException: method ID not in [0, 0xffff]: 65536
With -Pandroid.useDexArchive=false it looks like this
:app:transformClassesWithDesugarForNonpayItalyCompatDebugAndroidTest
:app:transformClassesWithPreDexForNonpayItalyCompatDebugAndroidTest
Dex: warning: Ignoring InnerClasses attribute for an anonymous inner class
(org.ccil.cowan.tagsoup.Parser$1) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
solution is to recompile the class from source, using an up-to-date compiler
and without specifying any "-target" type options. The consequence of ignoring
this warning is that reflective operations on this class will incorrectly
indicate that it is *not* an inner class.
:app:transformDexWithDexForNonpayItalyCompatDebugAndroidTest FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformDexWithDexForNonpayItalyCompatDebugAndroidTest'.
> com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: com.android.dex.DexIndexOverflowException: method ID not in [0, 0xffff]: 65536
ta...@gmail.com <ta...@gmail.com> #7
We updated our example repo https://github.com/originx/Gradle_troubles_android_enteprise where you can see the issue.
Just run
./gradlew spoonGermanyDebugAndroidTest
or
./gradlew spoonGermanyDebugAndroidTest -Pandroid.useDexArchive=false
and you will see the issue
Just run
./gradlew spoonGermanyDebugAndroidTest
or
./gradlew spoonGermanyDebugAndroidTest -Pandroid.useDexArchive=false
and you will see the issue
bu...@gmail.com <bu...@gmail.com> #8
Your tests do not fit into a single dex file. I've tried plugin 2.3.0 (I've also had to enable retrolambda for app, core, and pay modules), and the number of references that are generated is higher than 64k.
Please note that if you are using plugin's internal or Retrolamba support for Java 8 language features, for each lambda expression you will generate 3 additional references, so it might affect your reference count quite significantly.
Please note that if you are using plugin's internal or Retrolamba support for Java 8 language features, for each lambda expression you will generate 3 additional references, so it might affect your reference count quite significantly.
bu...@gmail.com <bu...@gmail.com> #9
Hello and thank you for the reply. What is the expected fix for this the ticket status was moved to "verified (fixed)" it is rather confusing for me. Do you suggest we have too many tests and that's it?
Could you please clarify?
Thank you for your time
Could you please clarify?
Thank you for your time
re...@gmail.com <re...@gmail.com> #10
Your test sources and test-only dependencies are generating too many references. Java 8 language features are not related to this, as even when I remove compileOptions from all modules, the test dependencies cannot fit into a single dex file.
I suggest you take a look at Proguard rules that you can specify when running the tests -https://google.github.io/android-gradle-dsl/current/com.android.build.gradle.internal.dsl.ProductFlavor.html#com.android.build.gradle.internal.dsl.ProductFlavor:testProguardFile(java.lang.Object) . I've also updated the bug status, not to be confusing.
I suggest you take a look at Proguard rules that you can specify when running the tests -
re...@gmail.com <re...@gmail.com> #11
Hello,
Thank you for the link and clarification.
Pardon my many questions I just want to understand the problem better.
We use proguard for the app and define proguard rules which classes to keep for the test runner that we need early on in the start of the test run.
Why did it work with older build tools?
Also why doesnt multidex work for the test app or proguard rules from the debug builds?
Thank you for the quick response
Thank you for the link and clarification.
Pardon my many questions I just want to understand the problem better.
We use proguard for the app and define proguard rules which classes to keep for the test runner that we need early on in the start of the test run.
Why did it work with older build tools?
Also why doesnt multidex work for the test app or proguard rules from the debug builds?
Thank you for the quick response
Description
Android Studio Version: 2021.3.1
Emulator Version (Emulator--> Extended Controls--> Emulator Version): 31.3.11-9058569
HAXM / KVM Version: HVF 12.6.0
Android SDK Tools: 26.1.1
Host Operating System: macOS 12.6
CPU Manufacturer: Other CPU:
64-bit CPU
RAM: 65536 MB
GPU:
Build Fingerprint:
AVD Details: Name: Pixel_5_API_33
CPU/ABI: arm64
Path: /Users/marikan/.android/avd/Pixel_5_API_33.avd
Target: google_apis [Google APIs] (API level 33)
Skin: 1080x2340
SD Card: 2G
AvdId: Pixel_5_API_33
PlayStore.enabled: false
avd.ini.displayname: Pixel 5 API 33
avd.ini.encoding: UTF-8
disk.dataPartition.size: 2G
fastboot.chosenSnapshotFile:
fastboot.forceChosenSnapshotBoot: no
fastboot.forceColdBoot: no
fastboot.forceFastBoot: yes
hw.accelerometer: yes
hw.arc: false
hw.audioInput: yes
hw.battery: yes
hw.camera.back: virtualscene
hw.camera.front: emulated
hw.cpu.ncore: 4
hw.dPad: no
hw.device.hash2: MD5:3274126e0242a0d86339850416b0ce34
hw.device.manufacturer: Google
hw.gps: yes
hw.gpu.enabled: yes
hw.gpu.mode: auto
hw.initialOrientation: Portrait
hw.keyboard: yes
hw.lcd.density: 440
hw.lcd.height: 2340
hw.lcd.width: 1080
hw.mainKeys: no
hw.ramSize: 1536
hw.sdCard: yes
hw.sensors.orientation: yes
hw.sensors.proximity: yes
hw.trackBall: no
image.sysdir.1: system-images/android-33/google_apis/arm64-v8a/
runtime.network.latency: none
runtime.network.speed: full
showDeviceFrame: yes
skin.dynamic: yes
tag.display: Google APIs
vm.heapSize: 512
Steps to Reproduce Bug:
Start emulator with "-timezone" parameter(e.g emulator -avd Pixel_5_API_33 -timezone Asia/Shanghai)
Issue is reproducible when API level of the emulator is set to 31+. When API level is 30 emulator works as expected
Expected Behavior:
Emulator starts with timezone set to provided parameter value
Observed Behavior:
Emulator ignores the parameter and starts with host devices timezone.