18

Building a cordova app with xwalk and it's no longer working.

ANDROID_HOME=C:\Program Files (x86)\Android\android-sdk JAVA_HOME=C:\Program Files\Java\jdk1.8.0_77 Reading build config file: f:\source\Cutter\Canvasser\build.json null embedded org.xwalk:xwalk_core_library:15+

FAILURE: Build failed with an exception.

BUILD FAILED

Total time: 4.251 secs

Connection to http://127.0.0.1:8888 refused

Can anyone help? I don't understand why it's a maven repository which can't be found.

JoshBerke
  • 66,142
  • 25
  • 126
  • 164
  • I have the same problem. repo1.maven.org returns 404. But download.01.org returns the xml file. – Jesús López May 04 '16 at 10:18
  • Are you behind the proxy network? @JoshBerke – NGB May 04 '16 at 10:37
  • @JoshBerke I suggest you to have a look at this link - http://stackoverflow.com/questions/36552511/crosswalk-could-not-resolve-all-dependencies-for-configuration-armv7debugcomp Basically for some reason 'xwalkVersion' preference value dint work with version+ value and was resolved by specifying a particular version.Hope it helps – Gandhi May 04 '16 at 10:45
  • @JoshBerke Also if you are behind proxy network, your corporation may be blocking https access.Infact there is also a request proposed to crosswalk project to make its components available in the maven central repository - https://crosswalk-project.org/jira/browse/XWALK-5164 More information can be found on the following link - https://github.com/infil00p/cordova-crosswalk-engine/issues/31 – Gandhi May 04 '16 at 11:12
  • I bet Fiddler is the culprit. It listens on 8888 port. But why gradle still uses the proxy when Fiddler is not running?. Where are the proxy settings in the project? – Jesús López May 04 '16 at 12:58
  • @JoshBerke It's Fiddler which causing this issue, it's best to use Intellij and use Cordova plugins. – Omer May 10 '16 at 13:45

4 Answers4

11

I had the same problem and finally solved it.

There is a file $(ProjectDir)platforms\android\gradle.properties that contains, What a surprise! Gradle properties. In my case the following was the content:

systemProp.http.proxyHost=127.0.0.1
systemProp.http.proxyPort=8888
systemProp.https.proxyHost=127.0.0.1
systemProp.https.proxyPort=8888

Just remove those entries, save the file and problem solved!

To reproduce the problem. Open Fiddler, create a new cordova project, add the xwalk plugin and build the project. You will see an authentication error. Close Fiddler, build the project again, you will see the error you have.

Moral: don't create cordova projects while Fiddler is running.

Jesús López
  • 8,338
  • 7
  • 40
  • 66
9

Check this link out: https://github.com/crosswalk-project/cordova-plugin-crosswalk-webview/issues/158

Here's the quote from the post:

"This can solve the issue for latest crosswalk version.

Open platforms\android\cordova-plugin-crosswalk-webview\eqp-xwalk.gradle

change this:

dependencies {
    xwalkSpec
}

to this one:

dependencies {
   compile 'org.xwalk:xwalk_core_library:23.53.589.4' //xwalkSpec
}

CrossWalk is discontinued, so you can left this and avoid future checks."

Hello
  • 91
  • 1
  • 1
  • I have a problem after replacing the compile parameter. An Error appears as below: otal time: 8.096 secs cmd: Command failed with exit code 1 Error output: FAILURE: Build failed with an exception. * What went wrong: A problem occurred configuring root project 'android'. > Could not resolve all dependencies for configuration ':_armv7DebugApkCopy'. > Could not find org.xwalk:xwalk_core_library:23.53.589.4. Required by: project : – Akira Chen Sep 09 '22 at 11:07
2

If you are receiving the following error after September 2017:

 Could not resolve org.xwalk:xwalk_core_library:23+.

Open

platforms\android\cordova-plugin-crosswalk-webview\eqp-xwalk.gradle in a regular cordova project

or

platforms\android\cordova-plugin-crosswalk-webview\starter-xwalk.gradle in an ionic project and replace

dependencies {
    xwalkSpec
}

with:

dependencies {
    compile 'org.xwalk:xwalk_core_library:23.53.589.4'
}
Peter Meadley
  • 509
  • 2
  • 16
-2
  1. Switch off your Wi-Fi for a good few moments (20 seconds maybe?)
  2. Turn that baby back on
  3. This actually worked for me
achabacha322
  • 651
  • 10
  • 32