Open dseeker opened 4 years ago
@YorkShen please help me to check this problem on https://github.com/weex-templates/weex-playground-android. @dseeker to update the latest template, you can use weex create [project-name] --no-cache
command after the problem has been fixed;
./gradlew assembleDebug
doesn't work as expceted and I have no clue here. You could try ./gradlew assembleRelease
, which works fine. @erha19 @dseeker Weex XXXX
, which is a serious vilolation of ASF trademark and happens in multliple places, unfortunaturely. Just use the offical Weex Playground. And if there is any missing feature, please let me know.
The default weex create project with platform android seems to have some native methods no longer supported or that needs revision because of package name changes. Projects using Nat.js library have stopped working with an error related to AbsWeexActivity file in registerBroadcastReceiver.
weex update [pluginname]@latest
).Your development environment
Check weex-toolkit verison (Run
weex -v
)@weex-cli/run : v2.0.0-beta.21
@weex-cli/device : v2.0.0-beta.2
@weex-cli/generator : v2.0.0-beta.16
@weex-cli/doctor : v2.0.0-beta.20
@weex-cli/plugin : v2.0.0-beta.22
@weex-cli/compile : v2.0.0-beta.27
Detact what's wrong with your environment (Run
weex doctor
)[✓] Android toolchain - develop for Android devices • Android SDK at /Users/dseeker/Library/Android/sdk • Platform android-29, build-tools 29.0.2 • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405).
[✓] iOS toolchain - develop for iOS devices • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 11.2 • CocoaPods version 1.8.4
✔ Weex Cli Environment (v2.0.0-beta.31, on darwin 19.0.0):
[✔] @weex-cli/core - core module for the weex-toolkit [✔] @weex-cli/run - module for running iOS/Android/Web platform with weex-toolkit [✔] @weex-cli/device - module for lanuch device with weex-toolkit [✔] @weex-cli/generator - Generator for weex-toolkit [✔] @weex-cli/doctor - Doctor module for weex-toolkit [✔] @weex-cli/plugin - Module for manage weex plugin and create plugin project [✔] @weex-cli/compile - Plugin for compile weex file.
[vue environment] check if there has Vue packages version mismatch issue
⠧ Error: Command failed: ./gradlew clean assembleDebug isLibProject: false, isAppProject: true weex_plugin: [{"dependency":"com.instapp.nat:weex-plugin-device-info:1.0.0-alpha","groupId":"com.instapp.nat","name":"weex-plugin-device-info","type":"maven","version":"1.0.0-alpha"}] add dependency "compile 'com.instapp.nat:weex-plugin-device-info:1.0.0-alpha'" /Users//demoapp/platforms/android/app/src/main/java/com/weex/app/AbsWeexActivity.java:400: error: cannot find symbol filter.addAction(WXSDKInstance.ACTION_DEBUG_INSTANCE_REFRESH); ^ symbol: variable ACTION_DEBUG_INSTANCE_REFRESH location: class WXSDKInstance /Users//demoapp/platforms/android/app/src/main/java/com/weex/app/AbsWeexActivity.java:495: error: cannot find symbol if (WXSDKInstance.ACTION_DEBUG_INSTANCE_REFRESH.equals(intent.getAction())) { ^ symbol: variable ACTION_DEBUG_INSTANCE_REFRESH location: class WXSDKInstance /Users//demoapp/platforms/android/app/src/main/java/com/weex/app/WXPageActivity.java:165: error: cannot find symbol if (TextUtils.equals(errCode, WXErrorCode.WX_DEGRAD_ERR_NETWORK_CHECK_CONTENT_LENGTH_FAILED.getErrorCode())) { ^ symbol: variable WX_DEGRAD_ERR_NETWORK_CHECK_CONTENT_LENGTH_FAILED location: class WXErrorCode Note: /Users//demoapp/platforms/android/app/src/main/java/com/weex/app/AbsWeexActivity.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. 3 errors
FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':app:compileDebugJavaWithJavac'.
Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
at ChildProcess.exithandler (child_process.js:294:12) at ChildProcess.emit (events.js:198:13) at maybeClose (internal/child_process.js:982:16) at Socket.stream.socket.on (internal/child_process.js:389:11) at Socket.emit (events.js:198:13) at Pipe._handle.close (net.js:606:12)
Steps to reproduce the problem.(Maybe a dotwe link)
weex plugin add nat-device-info
npm run android