apache / cordova-android Goto Github PK
View Code? Open in Web Editor NEWApache Cordova Android
Home Page: https://cordova.apache.org/
License: Apache License 2.0
Apache Cordova Android
Home Page: https://cordova.apache.org/
License: Apache License 2.0
we use html5 , and resumable.js to upload file.
but when we open file explorer(album)
pick some pics format like jpg png etc then cordova crashed
pick some document like txt pdf etc that it doesn't crash cordova but its seems just can't get file into input?
android 7x jianguopro2
Mozilla/5.0 (Linux; Android 7.1.1; OS105 Build/NGI77B) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.84 Mobile Safari/537.36
Android 6x google nexus 6
Android 8x google pixel 1
Android 9x google pixel 1
it likes you can list dir(album, file explorer), but can't read certain file.
I made an app about color blindness : https://github.com/healthonnet/ColorVisionQuiz-App
I use camera and apply SVG filters with feColorMatrix rules in order to simulated color blindness.
filter example :
<filter id="protanomaly">
<feColorMatrix
type="matrix"
values="0.817 0.183 0 0 0
0.333 0.667 0 0 0
0 0.125 0.875 0 0
0 0 0 1 0"/>
</filter>
Built with : (EDITED)
Everything works but not an Android 8, it just crashes the app. No error, nothing with adb logcat too.
feGaussianBlur
works.feColorMatrix
works on chrome DesktopfeColorMatrix
works on static DOM elementfeColorMatrix
Crashes when a video is running under the filter.As Oreo use the chrome Chrome/68.0.3440.85
it may comes from cordova ?
cordova-android currently has a few different ways to specify a minimum SDK version and the target SDK version, and they are not equally exposed at various levels of tooling, and they can override each other in non-obvious ways (to non-native Android devs).
Traditionally, we've relied on the <uses-sdk>
element in AndroidManifest.xml to specify the minimum, target, and (optionally) the maximum SDK versions. These can be customized via <preference>
elements in an app's config.xml (android-minSdkVersion
, android-targetSdkVersion
, and android-maxSdkVersion
respectively).
We also allow specifying these values via Gradle variables (cdvMinSdkVersion
, and cdvCompileSdkVersion
). If these variables are not specified, we default them.
According to Google's documentation:
If you specify API level requirements directly in your app's manifest file, the corresponding settings in the build files will override the settings in the manifest file. [...] [T]o avoid potential overwriting when the manifest is merged, you should remove these attributes from the
<uses-sdk>
element and define your API level settings in the Gradle build files instead.
In particular, I'm concerned about the possibility of someone specifying a minimum SDK version in config.xml, and that getting overridden by the default minimum SDK version of 19 via gradle.
Google seems to recommend using Gradle properties, which was also brought up in my PR about updating the Gradle build files.
It seems to me like the correct thing to do is to take the SDK versions specified in config.xml and transform them into both <uses-sdk>
attributes (as is done currently), but also into gradle properties. We don't currently have a good way to do that, but @erisu's PR #465 provides a gradle.properties file that we could inject cdvMinSdkVersion
and cdvCompileSdkVersion
into.
Thoughts/Concerns/Feedback?
Issue https://issues.apache.org/jira/browse/CB-14127 is not solved on version 7.1.1, RELEASESNOTES specify that google is above jcenter on build.gradle but on version 7.1.1 jcenter still above google causing an error on build process
I know that the issue is fixed in version --> 7.1.2
Could not find intellij-core.jar (com.android.tools.external.com-intellij:intellij-core:26.0.1).
Searched in the following locations:
https://jcenter.bintray.com/com/android/tools/external/com-intellij/intellij-core/26.0.1/intellij-core-26.0.1.jar
But when will be released the version 7.1.2?
Hi,
Any workaround for this issue? My cordova app receives this exception every day
Other similiar issue:
https://stackoverflow.com/questions/48457748/native-crash-in-abort-since-oreo-8-1
Why suddenly GMS started to appear in my Cordova Android build process and throws this error in Android Studio when i run an emulator?
I/System.out: waiting for debugger to settle...
I/System.out: debugger has settled (1447)
D/AndroidRuntime: Shutting down VM
E/AndroidRuntime: FATAL EXCEPTION: main
Process: ru.balumates.balu, PID: 4409
java.lang.RuntimeException: Unable to get provider com.google.android.gms.ads.MobileAdsInitProvider: java.lang.IllegalStateException:
******************************************************************************
* The Google Mobile Ads SDK was initialized incorrectly. AdMob publishers *
* should follow the instructions here: https://goo.gl/fQ2neu to add a valid *
* App ID inside the AndroidManifest. Google Ad Manager publishers should *
* follow instructions here: https://goo.gl/h17b6x. *
******************************************************************************
at android.app.ActivityThread.installProvider(ActivityThread.java:6242)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:5805)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5722)
at android.app.ActivityThread.-wrap1(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1656)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6494)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
Caused by: java.lang.IllegalStateException:
******************************************************************************
* The Google Mobile Ads SDK was initialized incorrectly. AdMob publishers *
* should follow the instructions here: https://goo.gl/fQ2neu to add a valid *
* App ID inside the AndroidManifest. Google Ad Manager publishers should *
* follow instructions here: https://goo.gl/h17b6x. *
******************************************************************************
at com.google.android.gms.internal.ads.zzmn.attachInfo(Unknown Source:17)
at com.google.android.gms.ads.MobileAdsInitProvider.attachInfo(Unknown Source:3)
at android.app.ActivityThread.installProvider(ActivityThread.java:6239)
... 10 more
Disconnected from the target VM, address: 'localhost:8600', transport: 'socket'
When I try to build my cordova android app I get the following build error:
`* What went wrong:
A problem occurred configuring project ':CordovaLib'.
Could not resolve all files for configuration ':CordovaLib:classpath'.
Could not find intellij-core.jar (com.android.tools.external.com-intellij:intellij-core:26.0.1).
Searched in the following locations:
https://jcenter.bintray.com/com/android/tools/external/com-intellij/intellij-core/26.0.1/intellij-core-26.0.1.jar`
The problem was supposedly fixed in :
https://cordova.apache.org/announcements/2018/07/18/cordova-android-7.1.1.html
but the build still fails.
I tracked it down to "/platforms/android/CordovaLib/build.gradle", where the jcenter repository is still in front of the maven repository.
When I change this manualy the build works just fine.
Please note: attempted to open JIRA issue for this, but was unable to add a bug to "Apache Cordova" project in the JIRA site for Apache (https://issues.apache.org/jira/projects/CB).
Attempting to build the "HelloWorld" Cordova app fails with the error:
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':app'.
> Failed to find target with hash string '27' in: C:\development\AndroidSDK
This seems to be pulled from "/platforms/android/CordovaLib/project.properties" file, "target=android-27" because changing to "target=aandroid-27" then shows the error "Failed to find target with hash string 'aandroid-27'". Changing back to "target=android-27" again and running "cordova build android" shows the error for value "27" without the "android-" part of the string.
Since the Android SDK puts the versions in folders such as "android-27"; it is clear that it cannot find that directory.
Since this is vanilla Cordova with only the base requirements from the documentation and the "HelloWorld" app created by Cordova, there are no third party extensions, etc. or other issues that should be causing this to throw this error.
The following are the steps that were taken to download and install requirements.
Then Cordova was loaded.
Then the steps to create the "HelloWorld" app were followed from the documentation (link in description). NOTE: a console screen print is attached of the commands and results at the end of this issue.
PowerShell screen commands and responses:
PS C:\> cd development
PS C:\development> cd github
PS C:\development\github> mkdir cordova-test
Directory: C:\development\github
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 10/4/2018 2:01 PM cordova-test
PS C:\development\github> cd cordova-test
PS C:\development\github\cordova-test> cordova create hello com.example.hello HelloWorld
Creating a new cordova project.
PS C:\development\github\cordova-test> dir
Directory: C:\development\github\cordova-test
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 10/4/2018 2:01 PM hello
PS C:\development\github\cordova-test> cd hello
PS C:\development\github\cordova-test\hello> dir
Directory: C:\development\github\cordova-test\hello
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 10/4/2018 2:01 PM hooks
d----- 10/4/2018 2:01 PM platforms
d----- 10/4/2018 2:01 PM plugins
d----- 10/4/2018 2:01 PM res
d----- 10/4/2018 2:01 PM www
-a---- 10/4/2018 2:01 PM 17 .npmignore
-a---- 10/4/2018 2:01 PM 984 config.xml
-a---- 10/4/2018 2:01 PM 366 package.json
PS C:\development\github\cordova-test\hello> cordova platform add android
Using cordova-fetch for cordova-android@~7.1.1
Adding android project...
Creating Cordova project for the Android platform:
Path: platforms\android
Package: com.example.hello
Name: HelloWorld
Activity: MainActivity
Android target: android-27
Android project created with [email protected]
Android Studio project detected
Android Studio project detected
Discovered plugin "cordova-plugin-whitelist" in config.xml. Adding it to the project
Installing "cordova-plugin-whitelist" for android
This plugin is only applicable for versions of cordova-android greater than 4.0. If you have a previous platform version, you do *not* need this plugin since the whitelist will be built in.
Adding cordova-plugin-whitelist to package.json
Saved plugin info for "cordova-plugin-whitelist" to config.xml
--save flag or autosave detected
Saving android@~7.1.1 into config.xml file ...
PS C:\development\github\cordova-test\hello> cordova requirements
Android Studio project detected
Requirements check results for android:
Java JDK: installed 1.8.0
Android SDK: installed true
Android target: installed android-28,android-27,android-26,android-25,android-24,android-23,android-22,android-21,android-20,android-19
Gradle: installed C:\Program Files\Android\Android Studio\gradle\gradle-4.6\bin\gradle
PS C:\development\github\cordova-test\hello> cordova build android
Android Studio project detected
ANDROID_HOME=C:\development\AndroidSDK
JAVA_HOME=C:\Java\jdk1.8.0_181
studio
Starting a Gradle Daemon, 2 incompatible Daemons could not be reused, use --status for details
BUILD SUCCESSFUL in 10s
1 actionable task: 1 executed
Subproject Path: CordovaLib
Subproject Path: app
publishNonDefault is deprecated and has no effect anymore. All variants are now published.
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
at build_648mpip0kozgkz3v7ai57q9rz.run(C:\development\github\cordova-test\hello\platforms\android\app\build.gradle:143)
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':app'.
> Failed to find target with hash string '27' in: C:\development\AndroidSDK
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 5s
cmd: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':app'.
> Failed to find target with hash string '27' in: C:\development\AndroidSDK
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 5s
PS C:\development\github\cordova-test\hello>
Hello,
I have android version 7.1.1 in my project
after adding android i build project using "cordova Build" command
And i got following error
See http://g.co/androidstudio/manifest-merger for more information about the manifest merger.
:app:processDebugManifest FAILED
uses-sdk:minSdkVersion 16 cannot be smaller than version 19 declared in library [:CordovaLib] C:\Users\trikonuser\TestAgain\WebCall_AS_tsim\webCall\platforms\android\CordovaLib\build\ intermediates\manifests\full\debug\AndroidManifest.xml as the library might be using APIs not available in 16
Suggestion: use a compatible library with a minSdk of at most 16,
or increase this project's minSdk version to at least 19,
or use tools:overrideLibrary="org.apache.cordova" to force usage (may lead to runtime failures)
Now magic is in my files
www/config.xml and xml/config.xml
<preference name="android-minSdkVersion" value="19" />
<preference name="android-targetSdkVersion" value="27"/>
and main/AndroidManifest.xml file I have put
<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="27" />
While My gradle file also contain
project.ext {
defaultBuildToolsVersion="27.0.1" //String
defaultMinSdkVersion=19 //Integer - Minimum requirement is Android 4.4
defaultTargetSdkVersion=27 //Integer - We ALWAYS target the latest by default
defaultCompileSdkVersion=27 //Integer - We ALWAYS compile with the latest by default
}
### BUT NOW I RUN COMMAND :- CORDOVA BUILD it changes all config i mad automatically to previous as follows
www/config.xml and xml/config.xml
<preference name="android-minSdkVersion" value="16" />
<preference name="android-targetSdkVersion" value="27"/>
and main/AndroidManifest.xml file I have put
<uses-sdk android:minSdkVersion="16" android:targetSdkVersion="27" />
How Cordova Build command run rechange agin to 16 if they already want to 19
I used below phonegap version
> <preference name="phonegap-version" value="cli-6.3.0" />
We are automating the build of APKs on CI, but the whole process is taking around 10 minutes and 80% of time is consumed by this phase.
Discovered plugin "cordova-plugin-statusbar" in config.xml. Adding it to the project
Installing "cordova-plugin-statusbar" for android
Adding cordova-plugin-statusbar to package.json
Saved plugin info for "cordova-plugin-statusbar" to config.xml`.
These are the plugins from config.xml
<plugin name="cordova-plugin-whitelist" spec="1.3.3" />
<plugin name="cordova-plugin-statusbar" spec="2.4.2" />
<plugin name="cordova-plugin-device" spec="2.0.2" />
<plugin name="cordova-plugin-splashscreen" spec="5.0.2" />
<plugin name="cordova-plugin-ionic-webview" spec="^2.0.0" />
<plugin name="phonegap-plugin-barcodescanner" spec="^8.0.0">
<variable name="ANDROID_SUPPORT_V4_VERSION" value="27.+" />
</plugin>
<plugin name="cordova-plugin-camera-preview" spec="^0.10.0" />
<plugin name="cordova-plugin-screen-orientation" spec="^3.0.1" />
<plugin name="cordova.plugins.diagnostic" spec="^4.0.10" />
<plugin name="cordova-android-support-gradle-release" spec="^1.4.4">
<variable name="ANDROID_SUPPORT_VERSION" value="26.+" />
</plugin>
<plugin name="cordova-sqlite-storage" spec="^2.4.0" />
<plugin name="cordova-plugin-ionic-keyboard" spec="^2.1.2" />
<plugin name="cordova-plugin-camera" spec="^4.0.3" />
Is it possible to speed up these process by somehow caching the results or any other way to speed up the installation of plugins?
Hi,
It seems like the method below is depricated and should be replaced with Fileproviders
From Android NDK v18 removed support:
mips64el-linux-android-4.9
mipsel-linux-android-4.9
cordova run android: fail
"No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android"
Loading the old archive NDK v17
https://developer.android.com/ndk/downloads/older_releases
and copy in local folder android-sdk > toolchains
Error occurs when trying to take picture with camera plugin. Abbreviated stack trace:
10-09 13:04:53.164: W/System.err(17950): java.lang.ClassNotFoundException: <application id>.BuildConfig
10-09 13:04:53.164: W/System.err(17950): at java.lang.Class.classForName(Native Method)
10-09 13:04:53.164: W/System.err(17950): at java.lang.Class.forName(Class.java:453)
10-09 13:04:53.164: W/System.err(17950): at java.lang.Class.forName(Class.java:378)
10-09 13:04:53.164: W/System.err(17950): at org.apache.cordova.BuildHelper.getBuildConfigValue(BuildHelper.java:54)
10-09 13:04:53.164: W/System.err(17950): at org.apache.cordova.camera.CameraLauncher.execute(CameraLauncher.java:140)
Error can be reproduced by defining applicationIdSuffix in build-extras.gradle, for example with
debug {
applicationIdSuffix ".debug"
versionNameSuffix ".debug"
}
The problem is caused by BuildHelper calling 'context.getPackageName', which returns the application id, not the package name.
Ironically, the application id is what CameraLauncher is trying to get in the first place, so I've been able to fix the problem modifying code in CameraLauncher:
Context context = cordova.getContext();
this.applicationId = context.getPackageName();
// this.applicationId = (String) BuildHelper.getBuildConfigValue(cordova.getActivity(), "APPLICATION_ID");
But I think this should really work out of the box... (maybe add a method to CordovaInterface to return BuildConfig, which could be informed optionally from the application's CordovaActivity implementation?)
I am working on Cordova, Angular5 and OnsenUI(CSS Only).
Now when i add backbutton event listener it should override with my call back, but it executes both, Can some one help me out
Note: Before integrated OnsenUI CSS, callback of backbutton working properly which means only Cordova with Angular5
The formula to set the version code for android generates a lower number for a later version.
If my math is right
18.8.240 =>181040
18.7.1015 => 181715
This results in App not installed message on android when upgrading.
Thanks.
cordova-android version: v8.0.0-dev
As part of the builders cleanup PR (#461), I removed all the builders except for the StudioBuilder. It turns out that the none
option is still invoked when the user uses the cordova run
command in a way that doesn't trigger a build (like if a build has been done just before it). This causes the run command to fail.
cc @erisu
I've been trying to work out why the min SDK was always being set to 19
even when I updated it to 23
every where possible.
I believe I've found an issue here https://github.com/apache/cordova-android/blob/master/bin/templates/project/app/build.gradle#L120 where it's setting the cdvMinSdkVersion
to null
when it's already null
, else if it's not null
it's setting it to the default min SDK version, meaning if you ever set a min SDK it will always change it to the default.
I believe the correct line should read:
ext.cdvMinSdkVersion = cdvMinSdkVersion == null ? defaultMinSdkVersion : cdvMinSdkVersion
I'm not sure if this is the correct place to put this, please tell where to ask if it isn't.
What I'm trying to do is embed a cordova application into a native android application.
It seems to me that the documentation is out of date or not clear about the steps that needs to be done.
I'm reading this: https://cordova.apache.org/docs/en/latest/guide/platforms/android/webview.html
I am at the point that I can't create the .jar
file for the following reasons.
/framework
directory in my root project directory or in platforms/android
gradle
instead of ant
for building the android project. I can't find a build.xml anywhere in the android project.My Cordova version: 8.0.0
As as followup question, I expect this .jar
file will also contain the plugins that my cordova project depends on, correct?
I am using ubuntu 16.04 and i have been stuck on this one for a week now, Whenever i type cordova requirements i get the following message
Android Studio project detected
Requirements check results for android:
Java JDK: installed 1.8.0
Android SDK: installed true
Android target: not installed
spawn EACCES
Gradle: installed /usr/lib/gradle/4.10.2/bin/gradle
Some of requirements check failed
i have tried adding android platform also but no luck
cordova version 8.1.2
jdk 1.8.0
gradle 4.10.2
I stuck in my old version Android App based on Codova
I updated My Android App to latest version [email protected]
Now where i used CordovaWebView for for Webview in my app as follows
<org.apache.cordova.CordovaWebView
android:id="@+id/cordovaWebCallWebView"
android:layout_width="match_parent"
android:layout_height="match_parent" />
but it's not present in latest version of Cordova. So I changed to it by below lines
<org.apache.cordova.engine.SystemWebView
android:id="@+id/SystemWebView"
android:layout_width="match_parent"
android:layout_height="match_parent" />
where i am using WebRtc for my App So I used following method of SystemWebView Class
cwv.setWebChromeClient(new WebChromeClient() {
@Override
public void onPermissionRequest(final PermissionRequest request) {
javaToJavascript.webrtcCallLog("web.java", "permission asked is"+Arrays.deepToString(request.getResources()),0); //This logs the type of permission asked
Log.i("The list of permission asked is ", Arrays.deepToString(request.getResources())); // this askes for android.webkit.resource.AUDIO_CAPTURE permission
getActivity().runOnUiThread(new Runnable() {
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
@Override
public void run() {
Log.i("Value Of the permission asked is ", request
.getOrigin().toString());
request.grant(request.getResources());
}
});
}
});
Now i got runtime error in my Main java file regarding classCastException
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.simCard.web/com.simCard.web.WebCall}: java.lang.ClassCastException: com.simCard.web.WebCall$1 cannot be cast to org.apache.cordova.engine.SystemWebChromeClient
How to solve This error ? Please any ones help will be grateful
Thank you
I have a simple <input type="file">
→ click on it → system file chooser dialog opens → i choose some file → D/SystemWebChromeClient: Receive file chooser URL: null
error is thrown.
Cordova 7.1.0
Android Platform 7.1.0
Android 5.0
Chrome 37
This is über critical bug — all 5.0 Androids are affected, i cannot upload user's profile picture, etc.
SystemWebView memory leak
Hi
i am following back on a previous issue that i raised , for web view , i am trying to have media streaming and media recording capabilties in android using cordova , everything else is fine apart from the web view and crosswalk is no longer maintained and doesn't support media stream / recording using WEB RTC is there any other way out to solve this problem or any other options for cordova .looking forward for your help
Thanks
Hi,
I'm trying to update my platform from 5.1.1 to 7.1.1 with the new cordova 8.0.0, but, when I try to build my app, the following error occurs:
Android Studio project detected
ANDROID_HOME=/opt/necessitas/android-sdk
JAVA_HOME=/home/sabia-dev/desenvolvimento/jdk/jdk1.8.0_172
studio
Subproject Path: CordovaLib
Subproject Path: app
publishNonDefault is deprecated and has no effect anymore. All variants are now published.
Failed to notify ProjectEvaluationListener.afterEvaluate(), but primary configuration failure takes precedence.
java.lang.IllegalStateException: compileSdkVersion is not specified.
at com.google.common.base.Preconditions.checkState(Preconditions.java:456)
at com.android.build.gradle.BasePlugin.createAndroidTasks(BasePlugin.java:590)
at com.android.build.gradle.BasePlugin.lambda$null$3(BasePlugin.java:555)
at com.android.builder.profile.ThreadRecorder.record(ThreadRecorder.java:81)
at com.android.build.gradle.BasePlugin.lambda$createTasks$4(BasePlugin.java:551)
at org.gradle.internal.event.BroadcastDispatch$ActionInvocationHandler.dispatch(BroadcastDispatch.java:91)
at org.gradle.internal.event.BroadcastDispatch$ActionInvocationHandler.dispatch(BroadcastDispatch.java:80)
at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:42)
at org.gradle.internal.event.BroadcastDispatch$SingletonDispatch.dispatch(BroadcastDispatch.java:230)
at org.gradle.internal.event.BroadcastDispatch$SingletonDispatch.dispatch(BroadcastDispatch.java:149)
at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:58)
at org.gradle.internal.event.BroadcastDispatch$CompositeDispatch.dispatch(BroadcastDispatch.java:324)
at org.gradle.internal.event.BroadcastDispatch$CompositeDispatch.dispatch(BroadcastDispatch.java:234)
at org.gradle.internal.event.ListenerBroadcast.dispatch(ListenerBroadcast.java:140)
at org.gradle.internal.event.ListenerBroadcast.dispatch(ListenerBroadcast.java:37)
at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:93)
at com.sun.proxy.$Proxy24.afterEvaluate(Unknown Source)
at org.gradle.configuration.project.LifecycleProjectEvaluator.notifyAfterEvaluate(LifecycleProjectEvaluator.java:75)
at org.gradle.configuration.project.LifecycleProjectEvaluator.doConfigure(LifecycleProjectEvaluator.java:69)
at org.gradle.configuration.project.LifecycleProjectEvaluator.access$100(LifecycleProjectEvaluator.java:33)
at org.gradle.configuration.project.LifecycleProjectEvaluator$ConfigureProject.run(LifecycleProjectEvaluator.java:103)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:49)
at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:651)
at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:133)
at org.gradle.execution.TaskPathProjectEvaluator.configure(TaskPathProjectEvaluator.java:35)
at org.gradle.execution.TaskPathProjectEvaluator.configureHierarchy(TaskPathProjectEvaluator.java:62)
at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:38)
at org.gradle.initialization.DefaultGradleLauncher$ConfigureBuild.run(DefaultGradleLauncher.java:246)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
at org.gradle.initialization.DefaultGradleLauncher.configureBuild(DefaultGradleLauncher.java:165)
at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:124)
at org.gradle.initialization.DefaultGradleLauncher.executeTasks(DefaultGradleLauncher.java:107)
at org.gradle.internal.invocation.GradleBuildController$1.call(GradleBuildController.java:78)
at org.gradle.internal.invocation.GradleBuildController$1.call(GradleBuildController.java:75)
at org.gradle.internal.work.DefaultWorkerLeaseService.withLocks(DefaultWorkerLeaseService.java:152)
at org.gradle.internal.invocation.GradleBuildController.doBuild(GradleBuildController.java:100)
at org.gradle.internal.invocation.GradleBuildController.run(GradleBuildController.java:75)
at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28)
at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
at org.gradle.tooling.internal.provider.ValidatingBuildActionRunner.run(ValidatingBuildActionRunner.java:32)
at org.gradle.launcher.exec.RunAsBuildOperationBuildActionRunner$1.run(RunAsBuildOperationBuildActionRunner.java:43)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
at org.gradle.launcher.exec.RunAsBuildOperationBuildActionRunner.run(RunAsBuildOperationBuildActionRunner.java:40)
at org.gradle.tooling.internal.provider.SubscribableBuildActionRunner.run(SubscribableBuildActionRunner.java:51)
at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:45)
at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:29)
at org.gradle.launcher.exec.BuildTreeScopeBuildActionExecuter.execute(BuildTreeScopeBuildActionExecuter.java:39)
at org.gradle.launcher.exec.BuildTreeScopeBuildActionExecuter.execute(BuildTreeScopeBuildActionExecuter.java:25)
at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:71)
at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:45)
at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:51)
at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:32)
at org.gradle.tooling.internal.provider.GradleThreadBuildActionExecuter.execute(GradleThreadBuildActionExecuter.java:36)
at org.gradle.tooling.internal.provider.GradleThreadBuildActionExecuter.execute(GradleThreadBuildActionExecuter.java:25)
at org.gradle.tooling.internal.provider.ParallelismConfigurationBuildActionExecuter.execute(ParallelismConfigurationBuildActionExecuter.java:43)
at org.gradle.tooling.internal.provider.ParallelismConfigurationBuildActionExecuter.execute(ParallelismConfigurationBuildActionExecuter.java:29)
at org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute(StartParamsValidatingActionExecuter.java:64)
at org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute(StartParamsValidatingActionExecuter.java:29)
at org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute(SessionFailureReportingActionExecuter.java:55)
at org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute(SessionFailureReportingActionExecuter.java:42)
at org.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute(SetupLoggingActionExecuter.java:58)
at org.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute(SetupLoggingActionExecuter.java:33)
at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:67)
at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:37)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:26)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:34)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:74)
at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:72)
at org.gradle.util.Swapper.swap(Swapper.java:38)
at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:72)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute(LogAndCheckHealth.java:55)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:62)
at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:82)
at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:50)
at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:297)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
at java.lang.Thread.run(Thread.java:748)
FAILURE: Build failed with an exception.
* Where:
Script '/var/www/html/produto/manager-journey/journey/platforms/android/cordova-plugin-crosswalk-webview/journey-xwalk.gradle' line: 31
* What went wrong:
A problem occurred evaluating script.
> /var/www/html/produto/manager-journey/journey/platforms/android/app/res/xml/config.xml (Arquivo ou diretório inexistente)
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 1s
(node:15589) UnhandledPromiseRejectionWarning: Error: /var/www/html/produto/manager-journey/journey/platforms/android/gradlew: Command failed with exit code 1 Error output:
Failed to notify ProjectEvaluationListener.afterEvaluate(), but primary configuration failure takes precedence.
java.lang.IllegalStateException: compileSdkVersion is not specified.
at com.google.common.base.Preconditions.checkState(Preconditions.java:456)
at com.android.build.gradle.BasePlugin.createAndroidTasks(BasePlugin.java:590)
at com.android.build.gradle.BasePlugin.lambda$null$3(BasePlugin.java:555)
at com.android.builder.profile.ThreadRecorder.record(ThreadRecorder.java:81)
at com.android.build.gradle.BasePlugin.lambda$createTasks$4(BasePlugin.java:551)
at org.gradle.internal.event.BroadcastDispatch$ActionInvocationHandler.dispatch(BroadcastDispatch.java:91)
at org.gradle.internal.event.BroadcastDispatch$ActionInvocationHandler.dispatch(BroadcastDispatch.java:80)
at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:42)
at org.gradle.internal.event.BroadcastDispatch$SingletonDispatch.dispatch(BroadcastDispatch.java:230)
at org.gradle.internal.event.BroadcastDispatch$SingletonDispatch.dispatch(BroadcastDispatch.java:149)
at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:58)
at org.gradle.internal.event.BroadcastDispatch$CompositeDispatch.dispatch(BroadcastDispatch.java:324)
at org.gradle.internal.event.BroadcastDispatch$CompositeDispatch.dispatch(BroadcastDispatch.java:234)
at org.gradle.internal.event.ListenerBroadcast.dispatch(ListenerBroadcast.java:140)
at org.gradle.internal.event.ListenerBroadcast.dispatch(ListenerBroadcast.java:37)
at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:93)
at com.sun.proxy.$Proxy24.afterEvaluate(Unknown Source)
at org.gradle.configuration.project.LifecycleProjectEvaluator.notifyAfterEvaluate(LifecycleProjectEvaluator.java:75)
at org.gradle.configuration.project.LifecycleProjectEvaluator.doConfigure(LifecycleProjectEvaluator.java:69)
at org.gradle.configuration.project.LifecycleProjectEvaluator.access$100(LifecycleProjectEvaluator.java:33)
at org.gradle.configuration.project.LifecycleProjectEvaluator$ConfigureProject.run(LifecycleProjectEvaluator.java:103)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:49)
at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:651)
at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:133)
at org.gradle.execution.TaskPathProjectEvaluator.configure(TaskPathProjectEvaluator.java:35)
at org.gradle.execution.TaskPathProjectEvaluator.configureHierarchy(TaskPathProjectEvaluator.java:62)
at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:38)
at org.gradle.initialization.DefaultGradleLauncher$ConfigureBuild.run(DefaultGradleLauncher.java:246)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
at org.gradle.initialization.DefaultGradleLauncher.configureBuild(DefaultGradleLauncher.java:165)
at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:124)
at org.gradle.initialization.DefaultGradleLauncher.executeTasks(DefaultGradleLauncher.java:107)
at org.gradle.internal.invocation.GradleBuildController$1.call(GradleBuildController.java:78)
at org.gradle.internal.invocation.GradleBuildController$1.call(GradleBuildController.java:75)
at org.gradle.internal.work.DefaultWorkerLeaseService.withLocks(DefaultWorkerLeaseService.java:152)
at org.gradle.internal.invocation.GradleBuildController.doBuild(GradleBuildController.java:100)
at org.gradle.internal.invocation.GradleBuildController.run(GradleBuildController.java:75)
at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28)
at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
at org.gradle.tooling.internal.provider.ValidatingBuildActionRunner.run(ValidatingBuildActionRunner.java:32)
at org.gradle.launcher.exec.RunAsBuildOperationBuildActionRunner$1.run(RunAsBuildOperationBuildActionRunner.java:43)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
at org.gradle.launcher.exec.RunAsBuildOperationBuildActionRunner.run(RunAsBuildOperationBuildActionRunner.java:40)
at org.gradle.tooling.internal.provider.SubscribableBuildActionRunner.run(SubscribableBuildActionRunner.java:51)
at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:45)
at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:29)
at org.gradle.launcher.exec.BuildTreeScopeBuildActionExecuter.execute(BuildTreeScopeBuildActionExecuter.java:39)
at org.gradle.launcher.exec.BuildTreeScopeBuildActionExecuter.execute(BuildTreeScopeBuildActionExecuter.java:25)
at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:71)
at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:45)
at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:51)
at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:32)
at org.gradle.tooling.internal.provider.GradleThreadBuildActionExecuter.execute(GradleThreadBuildActionExecuter.java:36)
at org.gradle.tooling.internal.provider.GradleThreadBuildActionExecuter.execute(GradleThreadBuildActionExecuter.java:25)
at org.gradle.tooling.internal.provider.ParallelismConfigurationBuildActionExecuter.execute(ParallelismConfigurationBuildActionExecuter.java:43)
at org.gradle.tooling.internal.provider.ParallelismConfigurationBuildActionExecuter.execute(ParallelismConfigurationBuildActionExecuter.java:29)
at org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute(StartParamsValidatingActionExecuter.java:64)
at org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute(StartParamsValidatingActionExecuter.java:29)
at org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute(SessionFailureReportingActionExecuter.java:55)
at org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute(SessionFailureReportingActionExecuter.java:42)
at org.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute(SetupLoggingActionExecuter.java:58)
at org.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute(SetupLoggingActionExecuter.java:33)
at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:67)
at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:37)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:26)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:34)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:74)
at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:72)
at org.gradle.util.Swapper.swap(Swapper.java:38)
at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:72)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute(LogAndCheckHealth.java:55)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:62)
at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:82)
at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:50)
at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:297)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
at java.lang.Thread.run(Thread.java:748)
FAILURE: Build failed with an exception.
* Where:
Script '/var/www/html/produto/manager-journey/journey/platforms/android/cordova-plugin-crosswalk-webview/journey-xwalk.gradle' line: 31
* What went wrong:
A problem occurred evaluating script.
> /var/www/html/produto/manager-journey/journey/platforms/android/app/res/xml/config.xml (Arquivo ou diretório inexistente)
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 1s
at ChildProcess.whenDone (/var/www/html/produto/manager-journey/journey/platforms/android/cordova/node_modules/cordova-common/src/superspawn.js:169:23)
at emitTwo (events.js:126:13)
at ChildProcess.emit (events.js:214:7)
at maybeClose (internal/child_process.js:925:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
(node:15589) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:15589) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Is that a known issue for the 8.0.0 version or am I doing something really wrong?
Cheers
Nikao
Hi,
I am trying to sign the Cordova app but every time Android Studios throws the below error
java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: AAPT2 error: check logs for details |
I have tried the below ways but no luck so far
android.enableAapt2=false
to gradle-wrapper.propertiesVersion Details
8.0.0
7.1.1
4.4
3.1
3.1.4
Please let me know a solution as this is a blocker.
Thanks
hi, i can't find any forum about cordova, so i put my question right there
We are working on a Cordova project where we are developing an app for Android. The app is working good, but for certain functionalities to work properly, we need to access index.js file located in parent-folder/www/js/index.js. We added our modifications there, but nothing from index.js is getting called. We have a simple console.log, which also we don't see. What are we missing?
index.js :
var app = {
// Application Constructor
initialize: function() {
document.addEventListener('deviceready', this.onDeviceReady.bind(this), false);
},
// deviceready Event Handler
//
// Bind any cordova events here. Common events are:
// 'pause', 'resume', etc.
onDeviceReady: function() {
console.log("i am so ready for u boyyyzzz!");
this.receivedEvent('deviceready');
window.addEventListener("click", function(event){
var closestA = event.closest("a");
//if(closestA && closestA.href && (closestA.getAttribute("download") !== undefined) && (closestA.getAttribute("download") !== null)){
var fileTransfer = new FileTransfer();
var uri = encodeURI(closestA.href);
var fileURL = "///storage/emulated/0/DCIM/myFile";
fileTransfer.download(
uri, fileURL, function(entry) {
console.log("download complete: " + entry.toURL());
},
function(error) {
console.log("download error source " + error.source);
console.log("download error target " + error.target);
console.log("download error code" + error.code);
}
);
//}
});
},
This is causing us a lot of issues as none of our external functions, especially download seems to be working. What are we doing wrong. Any insight would help, we are stuck on this for 2 days. Thank you.
Hi, recently upgraded Cordova, Gradle and Android SDKs on Windows 10.
Now receiving this build error:
Could not create service of type TransformedFileCache using DependencyManagementBuildSessionServices.createTransformedFileCache().
CLI after reinstall of Node, Android Studio and Gradle:
C:\WINDOWS\system32>npm install -g cordova
C:\Users\[[USERNAME]]\AppData\Roaming\npm\cordova ->
C:\Users\[[USERNAME]]\AppData\Roaming\npm\node_modules\cordova\bin\cordova
+ [email protected]
added 594 packages from 523 contributors in 157.447s
C:\WINDOWS\system32>cd C:\[[FOLDER]]
C:\[[FOLDER]]>cordova create app [[APP ID]] [[APP NAME]]
Creating a new cordova project.
C:\[[FOLDER]]>cd app
C:\[[FOLDER]]\app>cordova platform add android
Using cordova-fetch for cordova-android@~7.1.1
Adding android project...
Creating Cordova project for the Android platform:
Path: platforms\android
Package: [[APP ID]]
Name: [[APP NAME]]
Activity: MainActivity
Android target: android-27
Android project created with [email protected]
Android Studio project detected
Android Studio project detected
Discovered plugin "cordova-plugin-whitelist" in config.xml. Adding it to the project
Installing "cordova-plugin-whitelist" for android
This plugin is only applicable for versions of cordova-android greater than 4.0. If you have a previous platform version, you do *not* need this plugin since the whitelist will be built in.
Adding cordova-plugin-whitelist to package.json
Saved plugin info for "cordova-plugin-whitelist" to config.xml
--save flag or autosave detected
Saving android@~7.1.1 into config.xml file ...
C:\[[FOLDER]]\app>cordova build android
Android Studio project detected
ANDROID_HOME=C:\Users\[[USERNAME]]\AppData\Local\Android\Sdk
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_181
studio
Starting a Gradle Daemon (subsequent builds will be faster)
BUILD SUCCESSFUL in 2m 31s
1 actionable task: 1 executed
Subproject Path: CordovaLib
Subproject Path: app
Starting a Gradle Daemon, 1 incompatible Daemon could not be reused, use --status for details
FAILURE: Build failed with an exception.
* Where:
Build file 'C:\[[FOLDER]]\app\platforms\android\build.gradle' line: 28
* What went wrong:
A problem occurred evaluating root project 'android'.
> Could not create service of type TransformedFileCache using
DependencyManagementBuildSessionServices.createTransformedFileCache().
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 8s
cmd: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.
* Where:
Build file 'C:\[[FOLDER]]\app\platforms\android\build.gradle' line: 28
* What went wrong:
A problem occurred evaluating root project 'android'.
> Could not create service of type TransformedFileCache using
DependencyManagementBuildSessionServices.createTransformedFileCache().
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 8s
Already tried completely uninstalling and reinstalling Cordova, Gradle, Android Studio and Node. If anyone has any ideas it would be greatly appreciated.
I choose WorkManager to make a scheduled service that would help me post data to server when cordova based app is closed.
So, I start with including dependencies in build.gradle (Module:app)
dependencies {
implementation fileTree(dir: 'libs', include: '*.jar')
//>>>>THIS LINE HERE IS FOR WORKMANAGER and MULTIDEX
implementation "android.arch.work:work-runtime:1.0.0-alpha01"
implementation 'com.android.support:multidex:1.0.3'
// SUB-PROJECT DEPENDENCIES START
implementation(project(path: ":CordovaLib"))
compile "com.android.support:support-v4:24.1.1+"
// SUB-PROJECT DEPENDENCIES END
}
Now I run following commands
cordova clean
cordova build android
I get throw with an exception:
Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'.
java.lang.RuntimeException: java.lang.RuntimeException: com.android.builder.dexing.DexArchiveMergerException: Unable to merge dex
So, I add this line
android {
defaultConfig {
versionCode cdvVersionCode ?: new BigInteger("" + privateHelpers.extractIntFromManifest("versionCode"))
applicationId privateHelpers.extractStringFromManifest("package")
//>>>>THIS LINE HERE
multiDexEnabled true
if (cdvMinSdkVersion != null) {
minSdkVersion cdvMinSdkVersion
}
}
lintOptions {
abortOnError false;
}
compileSdkVersion cdvCompileSdkVersion
buildToolsVersion cdvBuildToolsVersion
I ran the clean and build commands again. Now, I get new exception:
Execution failed for task ':app:transformClassesWithMultidexlistForDebug'.
> java.io.IOException: Can't write [C:\Users\hjhkjn\Desktop\cordova\hjhkjnad\platforms\android\app\build\intermediates\multi-dex\debug\componentClasses.jar] (Can't read [C:\Users\hjhkjn\Desktop\cordova\hjhkjnad\platforms\android\app\build\intermediates\transforms\desugar\debug\19.jar(;;;;;;**.class)] (Duplicate zip entry [19.jar:android/support/v4/content/PermissionChecker$PermissionResult.class]))
I do get this error as well - https://i.stack.imgur.com/sZadD.png
Any help would be appreciated. Thank you
Hi all while i run WEB-RTC into cordova app the native browser android 4.0 does not support WEB-RTC , so can you please tell how to solve it apart from cross walk or is there any road map that cordova is planning for WEB-RTC
When using an AOT compiled version of a website the application doesn't load.
Might be an issue with cordova-cli, I'm not sure.
Project can be found here:
https://github.com/IsraelHikingMap/Site
Also, When I compile it with --release
flag android is telling me that the application is invalid and doesn't install it on my device... :-/
After updating cordova from 8 to 8.1.2 , i run cmd and run "cordova clean", then "cordova build --realse android" , it report that no file "xx/platforms/android/app/src/main/assets/www/cordova_plugin.js".
I open the directory"xx/platforms\android\app\src\main\assets" and find no files in it.
Hello,
I am having an issue, the camera plugin does not work anymore with the 7.1.1 version. But works with the 7.0.0
Anyone with this problem please?
Thank you.
I have a pdf file which can be edited through Adobe Acrobat. When I open the file straight away from Adobe Acrobat app and edit the file, and when I press the back button it gets saved automatically by Adobe Acrobat app, but when I open from Cordova application, it is opening with Adobe Acrobat app and I can also able to edit that, but when press the back button and come back to app, and once again hit the pdf file from the Cordova app, it is not showing the edited content (it happens only with above android 7 versions, but below android version 7 it is working fine from the app).
I open the file with this code from Cordova,
Uri path = Uri.fromFile(file);
PackageManager packageManager = this.cordova.getActivity().getPackageManager();
String application_id = "com.package.name";
try {
PackageInfo packageInfo = packageManager.getPackageInfo(
this.cordova.getActivity().getPackageName(), 0);
application_id = packageInfo.packageName
} catch (NameNotFoundException e1) {
e1.printStackTrace();
}
if (Build.VERSION.SDK_INT >= 24) {
path = FileProvider.getUriForFile(this.cordova.getActivity(), application_id + ".provider", file);
}
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
intent.addFlags(Intent.FLAG_GRANT_WRITE_URI_PERMISSION);
intent.setDataAndType(path, contentType);
cordova.getActivity().startActivity(intent);
Does it need any extra permission from the application or any other way? Thanks in advance!
A fix for this issue: https://issues.apache.org/jira/browse/CB-14165 has been merged recently through this PR:
But it's not release yet. It causes a lot of devs to have to pre-launch emulators.
Could you consider releasing a 7.1.2 version to include latest fixes, including this one?
When an android cordova plugin has a framework
dependency, StudioBuilder.js generates a deprecated compile
dependency instead of a implementation
dependency:
cordova run android --emulator
is not working on java installed via brew (both oracle and openjdk versions).
UnhandledPromiseRejectionWarning: CordovaError: Requirements check failed for JDK 1.8 or greater
UnhandledPromiseRejectionWarning: CordovaError: Requirements check failed for JDK 1.8 or greater
As far as I discovered file check_reqs.js is responsible, it has problem recognising java10 and java11 because javac -version outputs to stdout instead of stderr. Also the regex.
im used very standard webview without any plugin
and typing or write its very sloooow
this video explain my problem
https://streamable.com/me494
this is my plugins
"dependencies": {
"cordova-android": "^7.0.0",
"cordova-plugin-whitelist": "^1.3.3"
},
I am using ubuntu 16.04 and i have been stuck on this one for a week now, Whenever i type cordova requirements i get the following message
Android Studio project detected
Requirements check results for android:
Java JDK: installed 1.8.0
Android SDK: installed true
Android target: not installed
spawn EACCES
Gradle: installed /usr/lib/gradle/4.10.2/bin/gradle
Some of requirements check failed
i have tried adding android platform also but no luck
cordova version 8.1.2
jdk 1.8.0
gradle 4.10.2
What is this and what i should do with this?
Cordova CLI — 8.1.2
Cordova Android — 7.1.1
Android SDK Platform-Tools — 27.0.3
Gradle — 4.6-all
com.android.tools.build:gradle — 3.0.1
I am going to use chrome to debug my app,
When I click on the link under my app name, a blank page popped up, and shown a 404 error on it,
Any suggestions?
Could not find support-v4.jar (com.android.support:support-v4:26.1.0).
Searched in the following locations:
https://jcenter.bintray.com/com/android/support/support-v4/26.1.0/support-v4-26.1.0.jar
We are using cordova-android version 6.4.0
It's the same issue of #521
cordova -v
8.1.2 ([email protected])
cordova platform list
Installed platforms:
android 7.1.1
cordova build android
BUILD SUCCESSFUL in 0s
1 actionable task: 1 executed
Subproject Path: CordovaLib
Subproject Path: app
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':CordovaLib'.
> Could not resolve all files for configuration ':CordovaLib:classpath'.
> Could not find intellij-core.jar (com.android.tools.external.com-intellij:intellij-core:26.0.1).
Searched in the following locations:
https://jcenter.bintray.com/com/android/tools/external/com-intellij/intellij-core/26.0.1/intellij-core-26.0.1.jar
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
thank you
see also another recent report of same issue : https://forum.ionicframework.com/t/ionic-pro-package-failed-after-successful-deploy/145355
I found out about the crash from the Google play console for my app, so I don't have all the information about reproducing it. However, I have inspected the code indicated by the stack trace and have noticed two potential issues with CordovaWebViewImpl's showWebPage method.
If openExternal is false, it will attempt to load the url in the internal webview and also will start an intent to view it externally (as long as it matches the whitelist). See this if block. Previously it returned inside that if block, but this commit removed the return statement - possibly by mistake I speculate.
Passing a file url outside an app is no longer allowed as of Android 7, but that is being done here.
2 is what actually causes the crash, although by inspecting the stack trace I'm pretty sure openExternal is false, so fixing 1 would avoid the crash in my case.
This is the stack trace:
android.os.FileUriExposedException:
at android.os.StrictMode.onFileUriExposed (StrictMode.java:1960)
at android.net.Uri.checkFileUriExposed (Uri.java:2356)
at android.content.Intent.prepareToLeaveProcess (Intent.java:9881)
at android.content.Intent.prepareToLeaveProcess (Intent.java:9835)
at android.app.Instrumentation.execStartActivity (Instrumentation.java:1612)
at android.app.Activity.startActivityForResult (Activity.java:4501)
at org.apache.cordova.CordovaActivity.startActivityForResult (CordovaActivity.java:343)
at android.app.Activity.startActivityForResult (Activity.java:4459)
at android.app.Activity.startActivity (Activity.java:4820)
at android.app.Activity.startActivity (Activity.java:4788)
at org.apache.cordova.CordovaWebViewImpl.showWebPage (CordovaWebViewImpl.java:239)
at org.apache.cordova.CordovaActivity$2.run (CordovaActivity.java:379)
at android.app.Activity.runOnUiThread (Activity.java:6188)
at org.apache.cordova.CordovaActivity.onReceivedError (CordovaActivity.java:377)
at org.apache.cordova.CordovaActivity.onMessage (CordovaActivity.java:465)
at org.apache.cordova.CordovaActivity$1.onMessage (CordovaActivity.java:214)
at org.apache.cordova.PluginManager.postMessage (PluginManager.java:318)
at org.apache.cordova.CordovaWebViewImpl$1.run (CordovaWebViewImpl.java:164)
at android.os.Handler.handleCallback (Handler.java:790)
at android.os.Handler.dispatchMessage (Handler.java:99)
at android.os.Looper.loop (Looper.java:164)
at android.app.ActivityThread.main (ActivityThread.java:6518)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:807)
summary:
My cordova android project build failed with error like
Could not resolve all files for configuration ':classpath'.
Could not find com.android.tools.build:gradle:3.0.1.
Searched in the following locations:
https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.0.1/gradle-3.0.1.pom
https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.0.1/gradle-3.0.1.jar
while I can download these files in my browser and I have not any proxy conf in gradle.
I tried:
reinstalling gradle.
reinstalling android studio and build tools.
reinstalling cordova.
modify repositories in build.gradle to google(),maven(),jcenter and etc.
removing gradle cache folder.
reinstalling windows and installing all packages and stuffs from the beginning!
and many trick from stackOverflow and other websites.
my env:
windows 10
android studio 3.2.1
cordova 8.1.2 ([email protected])
gradle 4.6
jdk 1.8
inside build.gradle:
buildscript {
repositories {
google()
maven {
url "https://dl.google.com/dl/android/maven2"
}
// jcenter()
}
dependencies {
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
classpath 'com.android.tools.build:gradle:3.0.1'
}
}
allprojects {
repositories {
google()
maven {
url "https://dl.google.com/dl/android/maven2"
}
// jcenter()
}
//This replaces project.properties w.r.t. build settings
project.ext {
defaultBuildToolsVersion="27.0.1" //String
defaultMinSdkVersion=19 //Integer - Minimum requirement is Android 4.4
defaultTargetSdkVersion=27 //Integer - We ALWAYS target the latest by default
defaultCompileSdkVersion=27 //Integer - We ALWAYS compile with the latest by default
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
...
Hello there,
I'm building a Android app, specified all required fields on build.json upon running
"Cordova build Android --release --buildConfig"
It does generates app-release.apk which is actually signed by the keystore provided in build.json but when deploying that app on device/emulator chrome://inspect still able to detect and inspect Cordova app.
cordova -v
8.1.2 ([email protected])
cordova platform list
Installed platforms:
android 6.2.3
cordova build android
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_debugApkCopy'.
> Could not find com.android.support:support-core-ui:27.1.1.
Searched in the following locations:
/AppData/Local/Android/Sdk/extras/android/m2repository/com/android/support/support-core-ui/27.1.1/support-core-ui-27.1.1.pom
/AppData/Local/Android/Sdk/extras/android/m2repository/com/android/support/support-core-ui/27.1.1/support-core-ui-27.1.1.aar
/App/platforms/android/sdk-manager/com/android/support/support-core-ui/27.1.1/support-core-ui-27.1.1.aar
Required by:
project : > com.android.support:support-v4:27.1.1
> Could not find com.android.support:support-fragment:27.1.1.
Searched in the following locations:
/AppData/Local/Android/Sdk/extras/android/m2repository/com/android/support/support-fragment/27.1.1/support-fragment-27.1.1.pom
/AppData/Local/Android/Sdk/extras/android/m2repository/com/android/support/support-fragment/27.1.1/support-fragment-27.1.1.aar
/App/platforms/android/sdk-manager/com/android/support/support-fragment/27.1.1/support-fragment-27.1.1.aar
Required by:
project : > com.android.support:support-v4:27.1.1
> Could not find com.android.support:support-annotations:27.1.1.
Searched in the following locations:
/AppData/Local/Android/Sdk/extras/android/m2repository/com/android/support/support-annotations/27.1.1/support-annotations-27.1.1.pom
/AppData/Local/Android/Sdk/extras/android/m2repository/com/android/support/support-annotations/27.1.1/support-annotations-27.1.1.jar
/App/platforms/android/sdk-manager/com/android/support/support-annotations/27.1.1/support-annotations-27.1.1.jar
Required by:
project : > com.android.support:support-v4:27.1.1 > com.android.support:support-compat:27.1.1
project : > com.android.support:support-v4:27.1.1 > com.android.support:support-media-compat:27.1.1
project : > com.android.support:support-v4:27.1.1 > com.android.support:support-core-utils:27.1.1
> Could not find android.arch.lifecycle:runtime:1.1.0.
Searched in the following locations:
/AppData/Local/Android/Sdk/extras/android/m2repository/android/arch/lifecycle/runtime/1.1.0/runtime-1.1.0.pom
/AppData/Local/Android/Sdk/extras/android/m2repository/android/arch/lifecycle/runtime/1.1.0/runtime-1.1.0.aar
App/platforms/android/sdk-manager/android/arch/lifecycle/runtime/1.1.0/runtime-1.1.0.aar
Required by:
project : > com.android.support:support-v4:27.1.1 > com.android.support:support-compat:27.1.1
Everything worked fine yesterday.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.