@@ -223,13 +223,15 @@ private void logJSException(Exception e) {
223
223
if (e instanceof JavascriptException ) {
224
224
FLog .e (ReactConstants .TAG , "Exception in native call from JS" , e );
225
225
showNewError (
226
+ // NULLSAFE_FIXME[Nullable Dereference]
226
227
e .getMessage ().toString (), new StackFrame [] {}, JSEXCEPTION_ERROR_COOKIE , ErrorType .JS );
227
228
} else {
228
229
showNewJavaError (message .toString (), e );
229
230
}
230
231
}
231
232
232
233
@ Override
234
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
233
235
public void showNewJavaError (@ Nullable String message , Throwable e ) {
234
236
FLog .e (ReactConstants .TAG , "Exception in native call" , e );
235
237
showNewError (
@@ -242,16 +244,19 @@ public void showNewJavaError(@Nullable String message, Throwable e) {
242
244
* called.
243
245
*/
244
246
@ Override
247
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
245
248
public void addCustomDevOption (String optionName , DevOptionHandler optionHandler ) {
246
249
mCustomDevOptions .put (optionName , optionHandler );
247
250
}
248
251
249
252
@ Override
253
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
250
254
public void showNewJSError (String message , ReadableArray details , int errorCookie ) {
251
255
showNewError (message , StackTraceHelper .convertJsStackTrace (details ), errorCookie , ErrorType .JS );
252
256
}
253
257
254
258
@ Override
259
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
255
260
public void registerErrorCustomizer (ErrorCustomizer errorCustomizer ) {
256
261
if (mErrorCustomizers == null ) {
257
262
mErrorCustomizers = new ArrayList <>();
@@ -260,6 +265,7 @@ public void registerErrorCustomizer(ErrorCustomizer errorCustomizer) {
260
265
}
261
266
262
267
@ Override
268
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
263
269
public Pair <String , StackFrame []> processErrorCustomizers (Pair <String , StackFrame []> errorInfo ) {
264
270
if (mErrorCustomizers != null ) {
265
271
for (ErrorCustomizer errorCustomizer : mErrorCustomizers ) {
@@ -281,10 +287,12 @@ public void hideRedboxDialog() {
281
287
mRedBoxSurfaceDelegate .hide ();
282
288
}
283
289
290
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
284
291
public @ Nullable View createRootView (String appKey ) {
285
292
return mReactInstanceDevHelper .createRootView (appKey );
286
293
}
287
294
295
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
288
296
public void destroyRootView (View rootView ) {
289
297
mReactInstanceDevHelper .destroyRootView (rootView );
290
298
}
@@ -518,12 +526,14 @@ public View getView(int position, @Nullable View convertView, ViewGroup parent)
518
526
mDevOptionsDialog =
519
527
new AlertDialog .Builder (context )
520
528
.setCustomTitle (header )
529
+ // NULLSAFE_FIXME[Not Vetted Third-Party]
521
530
.setAdapter (
522
531
adapter ,
523
532
(dialog , which ) -> {
524
533
optionHandlers [which ].onOptionSelected ();
525
534
mDevOptionsDialog = null ;
526
535
})
536
+ // NULLSAFE_FIXME[Not Vetted Third-Party]
527
537
.setOnCancelListener (dialog -> mDevOptionsDialog = null )
528
538
.create ();
529
539
mDevOptionsDialog .show ();
@@ -538,6 +548,7 @@ private String getJSExecutorDescription() {
538
548
try {
539
549
return getReactInstanceDevHelper ().getJavaScriptExecutorFactory ().toString ();
540
550
} catch (IllegalStateException e ) {
551
+ // NULLSAFE_FIXME[Return Not Nullable]
541
552
return null ;
542
553
}
543
554
}
@@ -624,6 +635,7 @@ public boolean hasUpToDateJSBundleInCache() {
624
635
try {
625
636
String packageName = mApplicationContext .getPackageName ();
626
637
PackageInfo thisPackage =
638
+ // NULLSAFE_FIXME[Nullable Dereference]
627
639
mApplicationContext .getPackageManager ().getPackageInfo (packageName , 0 );
628
640
if (mJSBundleDownloadedFile .lastModified () > thisPackage .lastUpdateTime ) {
629
641
// Base APK has not been updated since we downloaded JS, but if app is using exopackage
@@ -663,6 +675,7 @@ private void resetCurrentContext(@Nullable ReactContext reactContext) {
663
675
if (mCurrentReactContext != null ) {
664
676
try {
665
677
URL sourceUrl = new URL (getSourceUrl ());
678
+ // NULLSAFE_FIXME[Nullable Dereference]
666
679
String path = sourceUrl .getPath ().substring (1 ); // strip initial slash in path
667
680
String host = sourceUrl .getHost ();
668
681
String scheme = sourceUrl .getProtocol ();
@@ -785,6 +798,7 @@ public void onProgress(
785
798
}
786
799
787
800
@ Override
801
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
788
802
public void onFailure (Exception cause ) {
789
803
UiThreadUtil .runOnUiThread (
790
804
DevSupportManagerBase .this ::hideSplitBundleDevLoadingView );
@@ -793,6 +807,7 @@ public void onFailure(Exception cause) {
793
807
},
794
808
bundleFile ,
795
809
bundleUrl ,
810
+ // NULLSAFE_FIXME[Parameter Not Nullable]
796
811
null );
797
812
});
798
813
}
@@ -821,6 +836,7 @@ public void isPackagerRunning(final PackagerStatusCallback callback) {
821
836
}
822
837
823
838
@ Override
839
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
824
840
public @ Nullable File downloadBundleResourceFromUrlSync (
825
841
final String resourceURL , final File outputFile ) {
826
842
return mDevServerHelper .downloadBundleResourceFromUrlSync (resourceURL , outputFile );
@@ -888,6 +904,7 @@ public void onProgress(
888
904
}
889
905
890
906
@ Override
907
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
891
908
public void onFailure (final Exception cause ) {
892
909
hideDevLoadingView ();
893
910
if (mBundleDownloadListener != null ) {
@@ -975,6 +992,7 @@ private void reload() {
975
992
// start shake gesture detector
976
993
if (!mIsShakeDetectorStarted ) {
977
994
mShakeDetector .start (
995
+ // NULLSAFE_FIXME[Parameter Not Nullable]
978
996
(SensorManager ) mApplicationContext .getSystemService (Context .SENSOR_SERVICE ));
979
997
mIsShakeDetectorStarted = true ;
980
998
}
@@ -1060,6 +1078,7 @@ private static String getReloadAppAction(Context context) {
1060
1078
}
1061
1079
1062
1080
@ Override
1081
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
1063
1082
public void setPackagerLocationCustomizer (
1064
1083
DevSupportManager .PackagerLocationCustomizer packagerLocationCustomizer ) {
1065
1084
mPackagerLocationCustomizer = packagerLocationCustomizer ;
@@ -1071,6 +1090,7 @@ public void setPackagerLocationCustomizer(
1071
1090
}
1072
1091
1073
1092
@ Override
1093
+ // NULLSAFE_FIXME[Inconsistent Subclass Parameter Annotation]
1074
1094
public @ Nullable SurfaceDelegate createSurfaceDelegate (String moduleName ) {
1075
1095
if (mSurfaceDelegateFactory == null ) {
1076
1096
return null ;
0 commit comments