Upgrade android plugin and gradle


I have android multi project setup which compiles fine with:

I thought to upgrade gradle to 2.3 and android plugin to 1.0.0. I applied the migration steps listed on android site for it and got those things right. I am getting compilation error which I am unable to understand why.

Some basic errors like as if the class file generated has some issue or what it cannot find symbols like snippet below:

error: constructor RestClient in class RestClient cannot be applied to given types;
RestClient rc = new RestClient(ctx);
required: no arguments
found: Context
reason: actual and formal argument lists differ in length

As I said earlier same thing compiles fine in older versions of gradle and android plugin. I am using jdk 8 and have tried setting src, target compatibility to 1.6 also but same issue. I have tried both windows cmd and cygwin.

If need more info please let me know.

gradle -v

Gradle 2.3

Build time: 2015-02-16 05:09:33 UTC
Build number: none
Revision: 586be72bf6e3df1ee7676d1f2a3afd9157341274

Groovy: 2.3.9
Ant: Apache Antâ„¢ version 1.9.3 compiled on December 23 2013
JVM: 1.8.0_25 (Oracle Corporation 25.25-b02)
OS: Windows 7 6.1 amd64



It looks like a dependency is missing/changed. Can you compare gradle dependencies between the two versions? It could be that you were relying on something that was provided automatically on an older version of the android plug-in.

I compared dependencies using gradle dependencies as well as custom task allDeps but did not find any thing that different that could cause issue. The old build script using android support lib which is not in new build script as per allDeps. https://dl.dropbox.com/s/u8t7qcgn1o07jj3/depends.zip?dl=0 you can see the outputs for two sets (2.3 means new one that fails to build and other one is working old one).