Fixed
Status Update
Comments
ra...@google.com <ra...@google.com>
ia...@gmail.com <ia...@gmail.com> #2
Project: platform/frameworks/support
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
https://android-review.googlesource.com/1123258
https://goto.google.com/android-sha1/b90079595f33f58fece04026a97faa0d243acdb1
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
su...@google.com <su...@google.com> #3
su...@google.com <su...@google.com> #4
Project: platform/frameworks/support
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically ( b/140759491 ).
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
https://android-review.googlesource.com/1288456
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically (
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
to...@googlemail.com <to...@googlemail.com> #5
I tried to use the ProGuard configuration which is linked in comment #3 in my project.
The release build fails and the following warnings are printed:
22:22:06.567 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.work.NonBlockingWorker { NonBlockingWorker(android.content.Context,androidx.work.WorkerParameters); }', but not the descriptor class 'androidx.work.WorkerParameters'
22:22:06.567 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.work.NonBlockingWorker { void internalInit(android.content.Context,androidx.work.WorkerParameters); }', but not the descriptor class 'androidx.work.WorkerParameters'
22:22:06.567 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.work.Worker { Worker(android.content.Context,androidx.work.WorkerParameters); }', but not the descriptor class 'androidx.work.WorkerParameters'
The app is opensource if you want to run the release build yourself. Here is the branch (WIP):
https://github.com/EventFahrplan/EventFahrplan/tree/workmanager
Please run: ./gradlew --info --debug aCcc34c3Release
The release build fails and the following warnings are printed:
22:22:06.567 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.work.NonBlockingWorker { NonBlockingWorker(android.content.Context,androidx.work.WorkerParameters); }', but not the descriptor class 'androidx.work.WorkerParameters'
22:22:06.567 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.work.NonBlockingWorker { void internalInit(android.content.Context,androidx.work.WorkerParameters); }', but not the descriptor class 'androidx.work.WorkerParameters'
22:22:06.567 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.work.Worker { Worker(android.content.Context,androidx.work.WorkerParameters); }', but not the descriptor class 'androidx.work.WorkerParameters'
The app is opensource if you want to run the release build yourself. Here is the branch (WIP):
Please run: ./gradlew --info --debug aCcc34c3Release
su...@google.com <su...@google.com> #6
Ah, that's because we have a typo in our Proguard file. Change WorkParameters to WorkerParameters.
to...@googlemail.com <to...@googlemail.com> #7
Thank you for quick reply. I changed this here:
https://github.com/EventFahrplan/EventFahrplan/commit/7567331dc69a303d5c423850a97bf29005ea7b1c
The release build still fails though. Here is a part of the log output:
23:43:15.760 [ERROR] [system.err] Note: there were 11 duplicate class definitions.
23:43:15.760 [ERROR] [system.err] (http://proguard.sourceforge.net/manual/troubleshooting.html#duplicateclass )
23:43:15.822 [QUIET] [system.out] Initializing...
23:43:15.827 [QUIET] [system.out] Note: the configuration refers to the unknown class 'androidx.work.impl.background.firebase.FirebaseJobScheduler'
23:43:15.845 [QUIET] [system.out] Note: the configuration refers to the unknown class 'androidx.work.WorkParameters'
23:43:15.857 [QUIET] [system.out] Note: the configuration refers to the unknown class 'androidx.work.impl.background.firebase.FirebaseJobScheduler'
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.273 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.273 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.273 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.285 [ERROR] [system.err] Warning: androidx.work.impl.background.systemjob.SystemJobService: can't find referenced method 'android.net.Network getNetwork()' in library class android.app.job.JobParameters
23:43:16.883 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobService
23:43:16.883 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobScheduler
23:43:16.911 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk8.JDK8PlatformImplementations
23:43:16.911 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE8PlatformImplementations
23:43:16.912 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk7.JDK7PlatformImplementations
23:43:16.912 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE7PlatformImplementations
23:43:16.914 [QUIET] [system.out] Note: kotlin.jvm.internal.Reflection: can't find dynamically referenced class kotlin.reflect.jvm.internal.ReflectionFactoryImpl
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class com.android.org.conscrypt.SSLParametersImpl
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class org.apache.harmony.xnet.provider.jsse.SSLParametersImpl
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform$CloseGuard: can't find dynamically referenced class dalvik.system.CloseGuard
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.ConscryptPlatform: can't find dynamically referenced class org.conscrypt.ConscryptEngineSocket
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.Platform: can't find dynamically referenced class sun.security.ssl.SSLContextImpl
The release build still fails though. Here is a part of the log output:
23:43:15.760 [ERROR] [system.err] Note: there were 11 duplicate class definitions.
23:43:15.760 [ERROR] [system.err] (
23:43:15.822 [QUIET] [system.out] Initializing...
23:43:15.827 [QUIET] [system.out] Note: the configuration refers to the unknown class 'androidx.work.impl.background.firebase.FirebaseJobScheduler'
23:43:15.845 [QUIET] [system.out] Note: the configuration refers to the unknown class 'androidx.work.WorkParameters'
23:43:15.857 [QUIET] [system.out] Note: the configuration refers to the unknown class 'androidx.work.impl.background.firebase.FirebaseJobScheduler'
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper: can't find referenced class sun.misc.Unsafe
23:43:16.272 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.273 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.273 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.273 [ERROR] [system.err] Warning: androidx.concurrent.futures.AbstractFuture$UnsafeAtomicHelper$1: can't find referenced class sun.misc.Unsafe
23:43:16.285 [ERROR] [system.err] Warning: androidx.work.impl.background.systemjob.SystemJobService: can't find referenced method 'android.net.Network getNetwork()' in library class android.app.job.JobParameters
23:43:16.883 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobService
23:43:16.883 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobScheduler
23:43:16.911 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk8.JDK8PlatformImplementations
23:43:16.911 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE8PlatformImplementations
23:43:16.912 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk7.JDK7PlatformImplementations
23:43:16.912 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE7PlatformImplementations
23:43:16.914 [QUIET] [system.out] Note: kotlin.jvm.internal.Reflection: can't find dynamically referenced class kotlin.reflect.jvm.internal.ReflectionFactoryImpl
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class com.android.org.conscrypt.SSLParametersImpl
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class org.apache.harmony.xnet.provider.jsse.SSLParametersImpl
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform$CloseGuard: can't find dynamically referenced class dalvik.system.CloseGuard
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.ConscryptPlatform: can't find dynamically referenced class org.conscrypt.ConscryptEngineSocket
23:43:16.944 [QUIET] [system.out] Note: okhttp3.internal.platform.Platform: can't find dynamically referenced class sun.security.ssl.SSLContextImpl
su...@google.com <su...@google.com> #8
I think your compileSdk is too low. WorkManager requires it to be 28 or higher: https://irina-dot-devsite.googleplex.com/topic/libraries/architecture/adding-components
I'm not sure why you are running into the warnings about Unsafe, but you can try using -dontwarn sun.misc.Unsafe in your proguard file to see if it helps. We haven't observed it ourselves.
For what it's worth, one of the notes is referring to WorkParameters still - are you sure it was changed properly?
I'm not sure why you are running into the warnings about Unsafe, but you can try using -dontwarn sun.misc.Unsafe in your proguard file to see if it helps. We haven't observed it ourselves.
For what it's worth, one of the notes is referring to WorkParameters still - are you sure it was changed properly?
to...@googlemail.com <to...@googlemail.com> #10
I changed the ProGuard configuration as you can see it in the GitHub repository. It matches with your change here https://android-review.googlesource.com/c/platform/frameworks/support/+/782087/2/work/workmanager/proguard-rules.pro if I don't miss anything. I cannot tell why "WorkParameters" is still listed. I verified the output once again by running ./gradlew clean --info --debug aCcc34c3Release. Feel free to run the build yourself. All you need to do is to create a random release-keystore and the app/gradle.properties from the app/gradle.properties.example.
So you saying when I want to migrate my app to targetSdkVersion 26 until November I need to raise the compileSdkVersion to 28 in order to use WorkManager? Using targetSdkVersion 26 with compileSdkVersion 28 won't work?
So you saying when I want to migrate my app to targetSdkVersion 26 until November I need to raise the compileSdkVersion to 28 in order to use WorkManager? Using targetSdkVersion 26 with compileSdkVersion 28 won't work?
su...@google.com <su...@google.com> #11
There shouldn't be any issues with targetSdkVersion 26 and compileSdkVersion 28.
to...@googlemail.com <to...@googlemail.com> #12
Okay. I will try that. Thanks.
Feel free to contact me if you are not able to build my project.
Feel free to contact me if you are not able to build my project.
to...@googlemail.com <to...@googlemail.com> #13
Does it suffice to raise the compileSdkVersion to 28 or do I also have to raise the version of the support library artifacts at the same time? I tried your suggestion in comment #11 but the build still fails.
ap...@google.com <ap...@google.com> #14
Project: platform/frameworks/support
Branch: androidx-master-dev
commit cee9ab55352f3ad506552afb4753baf8648b4c30
Author: Sumir Kataria <sumir@google.com>
Date: Mon Oct 08 14:20:57 2018
Fix class name in Proguard configuration.
Bug: 116296569
Test: N/A
Change-Id: I3525f9d2f3b06523cbe842b35f97014677879a64
M work/workmanager/proguard-rules.pro
https://android-review.googlesource.com/782087
https://goto.google.com/android-sha1/cee9ab55352f3ad506552afb4753baf8648b4c30
Branch: androidx-master-dev
commit cee9ab55352f3ad506552afb4753baf8648b4c30
Author: Sumir Kataria <sumir@google.com>
Date: Mon Oct 08 14:20:57 2018
Fix class name in Proguard configuration.
Bug: 116296569
Test: N/A
Change-Id: I3525f9d2f3b06523cbe842b35f97014677879a64
M work/workmanager/proguard-rules.pro
su...@google.com <su...@google.com> #15
Support library as well.
to...@googlemail.com <to...@googlemail.com> #16
Do the latest changes (WorkParameters -> WorkerParameters, NonBlockingWorker -> ListenableWorker) in the ProGuard configuration apply to WorkManager 1.0.0-alpha09 or 1.0.0-alpha10 or both?
su...@google.com <su...@google.com> #17
alpha10.
to...@googlemail.com <to...@googlemail.com> #18
su...@google.com <su...@google.com> #19
There isn't one for alpha09... it's already released. You can modify that commit and adapt it to alpha09.
Just change WorkParameters -> WorkerParameters.
Just change WorkParameters -> WorkerParameters.
to...@googlemail.com <to...@googlemail.com> #20
Which commit do you refer to? The link I posted show the history of the proguard-rules.pro commits. Since the file exists for a year I would have expected that there was a version of the file which shipped with WorkManager 1.0.0-alpha which was released by September 19, 2018.
Or do you mean that the proguard-rules.pro being shipped with WorkManager 1.0.0-alpha is buggy?
Or do you mean that the proguard-rules.pro being shipped with WorkManager 1.0.0-alpha is buggy?
su...@google.com <su...@google.com> #21
Yes, alpha09 had a bug. #19 suggests a modification to your app's proguard config to get around the issue. alpha10 should be out soon with the fix.
to...@googlemail.com <to...@googlemail.com> #22
Thank you for the clarification.
I prepared my test branch according to your recommendations (ProGuard, compileSdkVersion, targetSdkVersion, support libraries) as you can see here:
https://github.com/EventFahrplan/EventFahrplan/compare/master...workmanager
The release build however still fails:
00:20:09.182 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobService
00:20:09.182 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobScheduler
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk8.JDK8PlatformImplementations
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE8PlatformImplementations
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk7.JDK7PlatformImplementations
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE7PlatformImplementations
00:20:09.212 [QUIET] [system.out] Note: kotlin.jvm.internal.Reflection: can't find dynamically referenced class kotlin.reflect.jvm.internal.ReflectionFactoryImpl
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class com.android.org.conscrypt.SSLParametersImpl
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class org.apache.harmony.xnet.provider.jsse.SSLParametersImpl
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform$CloseGuard: can't find dynamically referenced class dalvik.system.CloseGuard
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.ConscryptPlatform: can't find dynamically referenced class org.conscrypt.ConscryptEngineSocket
00:20:09.229 [QUIET] [system.out] Note: okhttp3.internal.platform.Platform: can't find dynamically referenced class sun.security.ssl.SSLContextImpl
00:20:09.955 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.core.graphics.drawable.IconCompatParcelizer { android.support.v4.graphics.drawable.IconCompat read(androidx.versionedparcelable.VersionedParcel); }', but not the descriptor class 'androidx.versionedparcelable.VersionedParcel'
00:20:09.955 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.core.graphics.drawable.IconCompatParcelizer { void write(android.support.v4.graphics.drawable.IconCompat,androidx.versionedparcelable.VersionedParcel); }', but not the descriptor class 'androidx.versionedparcelable.VersionedParcel'
I prepared my test branch according to your recommendations (ProGuard, compileSdkVersion, targetSdkVersion, support libraries) as you can see here:
The release build however still fails:
00:20:09.182 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobService
00:20:09.182 [QUIET] [system.out] Note: androidx.work.impl.Schedulers: can't find dynamically referenced class androidx.work.impl.background.firebase.FirebaseJobScheduler
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk8.JDK8PlatformImplementations
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE8PlatformImplementations
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.jdk7.JDK7PlatformImplementations
00:20:09.210 [QUIET] [system.out] Note: kotlin.internal.PlatformImplementationsKt: can't find dynamically referenced class kotlin.internal.JRE7PlatformImplementations
00:20:09.212 [QUIET] [system.out] Note: kotlin.jvm.internal.Reflection: can't find dynamically referenced class kotlin.reflect.jvm.internal.ReflectionFactoryImpl
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class com.android.org.conscrypt.SSLParametersImpl
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class org.apache.harmony.xnet.provider.jsse.SSLParametersImpl
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.AndroidPlatform$CloseGuard: can't find dynamically referenced class dalvik.system.CloseGuard
00:20:09.228 [QUIET] [system.out] Note: okhttp3.internal.platform.ConscryptPlatform: can't find dynamically referenced class org.conscrypt.ConscryptEngineSocket
00:20:09.229 [QUIET] [system.out] Note: okhttp3.internal.platform.Platform: can't find dynamically referenced class sun.security.ssl.SSLContextImpl
00:20:09.955 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.core.graphics.drawable.IconCompatParcelizer { android.support.v4.graphics.drawable.IconCompat read(androidx.versionedparcelable.VersionedParcel); }', but not the descriptor class 'androidx.versionedparcelable.VersionedParcel'
00:20:09.955 [QUIET] [system.out] Note: the configuration keeps the entry point 'androidx.core.graphics.drawable.IconCompatParcelizer { void write(android.support.v4.graphics.drawable.IconCompat,androidx.versionedparcelable.VersionedParcel); }', but not the descriptor class 'androidx.versionedparcelable.VersionedParcel'
su...@google.com <su...@google.com> #23
These aren't failures (unless your configuration has a problem). As you can see, you have things listed from other libraries like okhttp as well.
to...@googlemail.com <to...@googlemail.com> #24
Maybe, I missing the specific part in the output. I pasted a large part of the lower end here: http://pastebin.de/8421/
ra...@google.com <ra...@google.com> #25
You need to add:
-dontwarn sun.misc.Unsafe
-dontwarn sun.misc.Unsafe
to...@googlemail.com <to...@googlemail.com> #26
Thank you. This made the release build succeed.
Can you please explain which library (version) introduces the Unsafe class?
Can you please explain which library (version) introduces the Unsafe class?
ri...@googlemail.com <ri...@googlemail.com> #27
I am still facing this issue with WorkManager-1.0.0-beta01
2018-12-31 01:40:32.701 2947-2977/de.aurora.mggvertretungsplan.debug E/WM-WorkerFactory: Could not instantiate de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker
java.lang.IllegalAccessException: Class java.lang.Class<androidx.work.WorkerFactory> cannot access method void de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker.<init>(android.content.Context, androidx.work.WorkerParameters) of class java.lang.Class<de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker>
at java.lang.reflect.Constructor.newInstance0(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
at androidx.work.WorkerFactory.createWorkerWithDefaultFallback(WorkerFactory.java:92)
at androidx.work.impl.WorkerWrapper.runWorker(WorkerWrapper.java:191)
at androidx.work.impl.WorkerWrapper.run(WorkerWrapper.java:125)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:764)
2018-12-31 01:40:32.701 2947-2977/de.aurora.mggvertretungsplan.debug E/WM-WorkerWrapper: Could not create Worker de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker
My code can be found athttps://github.com/d-Rickyy-b/MGGVertretungsplan .
I'd be very grateful for any kind of support.
2018-12-31 01:40:32.701 2947-2977/de.aurora.mggvertretungsplan.debug E/WM-WorkerFactory: Could not instantiate de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker
java.lang.IllegalAccessException: Class java.lang.Class<androidx.work.WorkerFactory> cannot access method void de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker.<init>(android.content.Context, androidx.work.WorkerParameters) of class java.lang.Class<de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker>
at java.lang.reflect.Constructor.newInstance0(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
at androidx.work.WorkerFactory.createWorkerWithDefaultFallback(WorkerFactory.java:92)
at androidx.work.impl.WorkerWrapper.runWorker(WorkerWrapper.java:191)
at androidx.work.impl.WorkerWrapper.run(WorkerWrapper.java:125)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:764)
2018-12-31 01:40:32.701 2947-2977/de.aurora.mggvertretungsplan.debug E/WM-WorkerWrapper: Could not create Worker de.aurora.mggvertretungsplan.services.DownloadTimeTableWorker
My code can be found at
I'd be very grateful for any kind of support.
ri...@googlemail.com <ri...@googlemail.com> #28
Okay... I feel pretty stupid now - it seems that my constructor was package-private and for workmanager to work, it needed to be public. Maybe the exception could point to that issue?
ra...@google.com <ra...@google.com> #29
That is correct. Worker must have a public constructor unless you instantiate it via your own WorkerFactory.
Description
Version used: 1.0.0-alpha09
When using ProGuard, the Worker(Context context, WorkerParameters) constructor isn't kept, leading to Workers being unable to be created:
DefaultWorkerFactory: Could not instantiate com.google.android.apps.muzei.sync.ProviderChangedWorker
DefaultWorkerFactory: java.lang.NoSuchMethodException: <init> []
DefaultWorkerFactory: at java.lang.Class.getConstructor0(Class.java:2327)
DefaultWorkerFactory: at java.lang.Class.getDeclaredConstructor(Class.java:2166)
DefaultWorkerFactory: at androidx.work.DefaultWorkerFactory.createWorker(DefaultWorkerFactory.java:58)
DefaultWorkerFactory: at androidx.work.impl.WorkerWrapper.runWorker(WorkerWrapper.java:180)
DefaultWorkerFactory: at androidx.work.impl.WorkerWrapper.run(WorkerWrapper.java:117)
DefaultWorkerFactory: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
DefaultWorkerFactory: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
DefaultWorkerFactory: at java.lang.Thread.run(Thread.java:764)
WorkerWrapper: Could for create Worker com.google.android.apps.muzei.sync.ProviderChangedWorker
I had to manually add the ProGuard rule:
-keepclassmembers class * extends androidx.work.Worker {
public <init>(android.content.Context,androidx.work.WorkerParameters);
}