You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following warnings prevent building grpc-binder with -PfailOnWarnings=true, which sets -Werror. class file for android.annotation.RequiresPermission not found in particular is pretty nasty as it isn't clear what is going on and you can't silence the single warning.
> Task :grpc-binder:compileDebugUnitTestJavaWithJavac
grpc-java/binder/src/test/java/io/grpc/binder/internal/ParcelableInputStreamTest.java:91: warning: [deprecation] <T>readParcelable(ClassLoader) in Parcel has been deprecated
assertThat((TestParcelable) parcel.readParcelable(getClass().getClassLoader()))
^
where T is a type-variable:
T extends Parcelable declared in method <T>readParcelable(ClassLoader)
grpc-java/binder/src/test/java/io/grpc/binder/internal/ParcelableInputStreamTest.java:116: warning: [deprecation] <T>readParcelable(ClassLoader) in Parcel has been deprecated
assertThat((TestParcelable) parcel.readParcelable(getClass().getClassLoader()))
^
where T is a type-variable:
T extends Parcelable declared in method <T>readParcelable(ClassLoader)
~/.gradle/caches/modules-2/files-2.1/org.robolectric/shadows-framework/4.9.2/8854520515f61e7f8319534dbbea3071cd282c54/shadows-framework-4.9.2.jar(/org/robolectric/shadows/ShadowDevicePolicyManager.class): warning: Cannot find annotation method 'value()' in type 'RequiresPermission': class file for android.annotation.RequiresPermission not found
~/.gradle/caches/modules-2/files-2.1/org.robolectric/shadows-framework/4.9.2/8854520515f61e7f8319534dbbea3071cd282c54/shadows-framework-4.9.2.jar(/org/robolectric/shadows/ShadowDevicePolicyManager.class): warning: Cannot find annotation method 'value()' in type 'RequiresPermission'
~/.gradle/caches/modules-2/files-2.1/org.robolectric/shadows-framework/4.9.2/8854520515f61e7f8319534dbbea3071cd282c54/shadows-framework-4.9.2.jar(/org/robolectric/shadows/ShadowDevicePolicyManager.class): warning: Cannot find annotation method 'value()' in type 'RequiresPermission'
~/clients/grpc-java/binder/src/test/java/io/grpc/binder/SecurityPoliciesTest.java:532: warning: [deprecation] signatures in PackageInfo has been deprecated
packageInfo.signatures = this.signatures;
^
6 warnings
Yeah, I agree, but at the very least we can add @SuppressWarnings("deprecations") with a comment to the code. I would have done that in #10299 (where this came up), but that RequiresPermission thing was super strange.
It does seem an issue with Robolectric, but I'm also not clear on why Robolectric would be using the private versions of those annotations. I did try upgrading to the newest Robolectric and the issue was still present.
The following warnings prevent building grpc-binder with
-PfailOnWarnings=true
, which sets-Werror
.class file for android.annotation.RequiresPermission not found
in particular is pretty nasty as it isn't clear what is going on and you can't silence the single warning.CC @markb74, @jdcormie
The text was updated successfully, but these errors were encountered: