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

cordova build android : Could not find intellij-core.jar #521

Closed
mccob opened this issue Oct 23, 2018 · 12 comments
Closed

cordova build android : Could not find intellij-core.jar #521

mccob opened this issue Oct 23, 2018 · 12 comments

Comments

@mccob
Copy link

mccob commented Oct 23, 2018

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

@KristoferGoransson
Copy link

KristoferGoransson commented Oct 23, 2018

I also got the same issue today :/

@vicenteaige
Copy link

I got the same error but with the support-v4-27.1.1.jar. I was able to build a few days ago.

@arnoldsi-tr
Copy link

Hi,
The issue happened due the removal of jar file from the repository:
https://bintray.com/bintray/jcenter/com.android.tools.external.com-intellij:intellij-core/26.0.1#files/com%2Fandroid%2Ftools%2Fexternal%2Fcom-intellij%2Fintellij-core%2F26.0.1

There is a fix for it that should be implemented in cordovalib:
open:
platforms\android\CordovaLib\build.gradle

Replace the order of repositories from:
repositories { jcenter() maven { url "https://maven.google.com" } }

to:
repositories { maven { url "https://maven.google.com" } jcenter() }

I think this fix should be also implemented in cordova

@mccob
Copy link
Author

mccob commented Oct 23, 2018

working after an platform remove and add

@arnoldsi-tr
Copy link

arnoldsi-tr commented Oct 23, 2018

@mccob nope, not for me. The url of package is still broken.
Which cordova CLI and android target you are running?

@mccob
Copy link
Author

mccob commented Oct 23, 2018

android target : cordova default

cordova -v
8.1.2 ([email protected])

cordova platform list
Installed platforms:
android 7.1.1

@arnoldsi-tr
Copy link

@mccob there is nothing changed in version 7.1.1 regarding this issue. You currently have cached gradle, therfore it working for you. On clean server or environment it won't work because the file doesn't exist (it was removed today, probably by mistake)

@mccob
Copy link
Author

mccob commented Oct 23, 2018

it's working because I have updated build.gradle as you explain (after platform rm / add)

@arnoldsi-tr
Copy link

@mccob this is temporary solution. Usually you shouldn't save the platform as part of you project and add it according to environment you running on.
Cordova guys should fix the issue :)

@dpogue
Copy link
Member

dpogue commented Oct 23, 2018

Part of the proposed change to move the Google Maven repo ahead of jcentre has already been made and released in cordova-android 7.1.1. However, the build.gradle file in the CordovaLib project did not get updated.

We'll be doing further gradle updates in the next major version for compatibility with updated Android SDKs, so I'll make sure it gets fixed there.

@arnoldsi-tr
Copy link

@dpogue can't it be a hotfix for current major version? I think it's very important to fix this issue

@dpogue
Copy link
Member

dpogue commented Oct 23, 2018

It sounds like the root issue here is that stuff got published to bintray with broken dependencies. Changing the Cordova dependencies is working around the problem, but not actually fixing it (because it's entirely outside the scope of anything we can control).

We can make the gradle file change and try to do a 7.1.2 release, but it's going to take at least a few days before that can be published. Speaking for myself, I won't be able to even start the release process and submit it to the list for voting until mid-next week at the earliest.

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