Skip to content
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

Task :react-native-picker:compileReleaseJavaWithJavac FAILED #412

Open
frontend-qin opened this issue Sep 8, 2020 · 2 comments
Open

Task :react-native-picker:compileReleaseJavaWithJavac FAILED #412

frontend-qin opened this issue Sep 8, 2020 · 2 comments

Comments

@frontend-qin
Copy link

Task :react-native-picker:compileReleaseJavaWithJavac FAILED
D:\code_registy\qiye_app\node_modules\react-native-picker\android\src\main\java\com\beefe\picker\PickerViewModule.java:9: 错误: 程序包android.support.annotation不存在
import android.support.annotation.Nullable;
^
D:\code_registy\qiye_app\node_modules\react-native-picker\android\src\main\java\com\beefe\picker\PickerViewModule.java:533: 错误: 找不到符号
@nullable WritableMap params) {
^
符号: 类 Nullable
位置: 类 PickerViewModule
注: D:\code_registy\qiye_app\node_modules\react-native-picker\android\src\main\java\com\beefe\picker\PickerViewModule.java使用或覆盖了已过时的 API。
注: 有关详细信息, 请使用 -Xlint:deprecation 重新编译。
2 个错误

@finghtingjie
Copy link

react-native-picker\android\src\main\java\com\beefe\picker\PickerViewModule.java:9
把第九行改为
import androidx.annotation.Nullable;
然后找到react-native-picker里的build.gradle
node_modules/react-native-picker/android/build.gradle
修改
compileSdkVersion 29
buildToolsVersion "29.0.2"
targetSdkVersion 29
这三个版本改成你自己项目里android目录下的gradle里buildscript的版本号一致就行了。

@Arnav7501
Copy link

answer in english please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants