-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Execution failed for task ':react-native-background-job:compileDebugJavaWithJavac'. #134
Comments
Hi, @kishansbs don't know how you use the library, but preventing Jetifier from migrating to AndroidX seems to solve this issue.
Please let me know weather it solved your problem ? |
Change like this: |
Thanks bro, this working for me. Changing the line where the error pointed out from 'android.support' to 'androidx'. |
Task :react-native-background-job:compileDebugJavaWithJavac FAILED
warning: [options] source value 7 is obsolete and will be removed in a future release
warning: [options] target value 7 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/ReactNativeEventStarter.java:7: error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
^
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/Utils.java:3: error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
^
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/BackgroundJobModule.java:7: error: package android.support.annotation does not exist
import android.support.annotation.Nullable;
^
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/ExactJob.java:6: error: package android.support.annotation does not exist
import android.support.annotation.Nullable;
^
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/ReactNativeEventStarter.java:29: error: cannot find symbol
public ReactNativeEventStarter(@nonnull Context context) {
^
symbol: class NonNull
location: class ReactNativeEventStarter
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/ReactNativeEventStarter.java:34: error: cannot find symbol
public void trigger(@nonnull Bundle jobBundle) {
^
symbol: class NonNull
location: class ReactNativeEventStarter
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/Utils.java:14: error: cannot find symbol
public static boolean isReactNativeAppInForeground(@nonnull ReactNativeHost reactNativeHost) {
^
symbol: class NonNull
location: class Utils
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/BackgroundJobModule.java:146: error: cannot find symbol
@nullable @OverRide public Map<String, Object> getConstants() {
^
symbol: class Nullable
location: class BackgroundJobModule
/Users/machd/Desktop/RN_Projects/projectname/node_modules/react-native-background-job/android/src/main/java/com/pilloxa/backgroundjob/ExactJob.java:14: error: cannot find symbol
@OverRide protected void onHandleIntent(@nullable Intent intent) {
^
symbol: class Nullable
location: class ExactJob
9 errors
3 warnings
FAILURE: Build failed with an exception.
Execution failed for task ':react-native-background-job:compileDebugJavaWithJavac'.
The text was updated successfully, but these errors were encountered: