# \<Kotlin-for-Android-Developers\> demo can not run any more in AS beta 5

**URL:** <https://discuss.kotlinlang.org/t/kotlin-for-android-developers-demo-can-not-run-any-more-in-as-beta-5/1482>\
**Category:** Android\
**Created:** [February 19, 2016, 3:03am UTC](https://discuss.kotlinlang.org/t/kotlin-for-android-developers-demo-can-not-run-any-more-in-as-beta-5/1482 "2016-02-19T03:03:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![watsonyao](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/watsonyao/32/1823_2.png) [@watsonyao](https://discuss.kotlinlang.org/u/watsonyao)\
**Post date:** [February 19, 2016, 3:03am UTC](https://discuss.kotlinlang.org/t/kotlin-for-android-developers-demo-can-not-run-any-more-in-as-beta-5/1482/1 "2016-02-19T03:03:28Z")

</div>

## [GitHub - antoniolg/Kotlin-for-Android-Developers: Companion App for the book](https://github.com/antoniolg/Kotlin-for-Android-Developers) it’s OK when run the demo above in stable AS not OK when run the demo above in AS 2.0 beta 5

apply plugin: ‘com.android.application’  
apply plugin: ‘kotlin-android’  
apply plugin: ‘kotlin-android-extensions’

android {  
compileSdkVersion 23  
buildToolsVersion “23.0.2”

```
defaultConfig {
    applicationId "com.antonioleiva.weatherapp"
    minSdkVersion 15
    targetSdkVersion 23
    versionCode 1
    versionName "1.0"

    testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}

buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}

```

}

dependencies {  
compile fileTree(dir: ‘libs’, include: [‘\*.jar’])  
compile “com.android.support:appcompat-v7:$support\_version”  
compile “com.android.support:recyclerview-v7:$support\_version”  
compile “org.jetbrains.kotlin:kotlin-stdlib:$kotlin\_version”  
compile “org.jetbrains.anko:anko-common:$anko\_version”  
compile “org.jetbrains.anko:anko-sqlite:$anko\_version”  
compile “com.google.code.gson:gson:2.4”  
compile “com.squareup.picasso:picasso:2.5.2”  
testCompile “junit:junit:4.12”  
testCompile “org.mockito:mockito-core:1.10.19”  
androidTestCompile “com.android.support:support-annotations:$support\_version”  
androidTestCompile “com.android.support.test:runner:0.4.1”  
androidTestCompile “com.android.support.test:rules:0.4.1”  
androidTestCompile “com.android.support.test.espresso:espresso-core:2.2.1”  
androidTestCompile (“com.android.support.test.espresso:espresso-contrib:2.2.1”){  
exclude group: ‘com.android.support’, module: ‘appcompat’  
exclude group: ‘com.android.support’, module: ‘support-v4’  
exclude module: ‘recyclerview-v7’  
}  
}

* * *

buildscript {  
ext.support\_version = ‘23.1.1’  
ext.kotlin\_version = ‘1.0.0’  
ext.anko\_version = ‘0.8.2’  
repositories {  
jcenter()  
}  
dependencies {  
classpath ‘com.android.tools.build:gradle:1.5.0’  
classpath “org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin\_version”  
}  
}

allprojects {  
repositories {  
jcenter()  
}  
}

Message ---------------------------------------------------  
Information:Gradle tasks [:app:assembleDebug]  
:app:preBuild UP-TO-DATE  
:app:preDebugBuild UP-TO-DATE  
:app:checkDebugManifest  
:app:preReleaseBuild UP-TO-DATE  
:app:prepareComAndroidSupportAppcompatV72311Library UP-TO-DATE  
:app:prepareComAndroidSupportRecyclerviewV72311Library UP-TO-DATE  
:app:prepareComAndroidSupportSupportV42311Library UP-TO-DATE  
:app:prepareDebugDependencies  
:app:compileDebugAidl UP-TO-DATE  
:app:compileDebugRenderscript UP-TO-DATE  
:app:generateDebugBuildConfig UP-TO-DATE  
:app:generateDebugAssets UP-TO-DATE  
:app:mergeDebugAssets UP-TO-DATE  
:app:generateDebugResValues UP-TO-DATE  
:app:generateDebugResources UP-TO-DATE  
:app:mergeDebugResources UP-TO-DATE  
:app:processDebugManifest UP-TO-DATE  
:app:processDebugResources UP-TO-DATE  
:app:generateDebugSources UP-TO-DATE  
:app:compileDebugKotlin  
/Users/nian-watson/Downloads/Kotlin-for-Android-Developers-master 2/app/src/main/java/com/antonioleiva/weatherapp/ui/activities/DetailActivity.kt  
Error:(30, 8) Unresolved reference: kotlinx  
Error:(58, 46) Unresolved reference: icon  
Error:(60, 9) Unresolved reference: weatherDescription  
Error:(61, 29) Unresolved reference: maxTemperature  
Error:(61, 52) Unresolved reference: minTemperature  
/Users/nian-watson/Downloads/Kotlin-for-Android-Developers-master 2/app/src/main/java/com/antonioleiva/weatherapp/ui/activities/MainActivity.kt  
Error:(28, 8) Unresolved reference: kotlinx  
Error:(45, 9) Unresolved reference: forecastList  
Error:(46, 24) Unresolved reference: forecastList  
Error:(62, 13) Unresolved reference: forecastList  
/Users/nian-watson/Downloads/Kotlin-for-Android-Developers-master 2/app/src/main/java/com/antonioleiva/weatherapp/ui/activities/SettingsActivity.kt  
Error:(24, 8) Unresolved reference: kotlinx  
Error:(25, 8) Unresolved reference: kotlinx  
Error:(39, 29) Unresolved reference: toolbar  
Error:(41, 9) Unresolved reference: cityCode  
Error:(46, 19) Unresolved reference: cityCode  
/Users/nian-watson/Downloads/Kotlin-for-Android-Developers-master 2/app/src/main/java/com/antonioleiva/weatherapp/ui/adapters/ForecastListAdapter.kt  
Error:(29, 8) Unresolved reference: kotlinx  
Error:(49, 72) Unresolved reference: icon  
Error:(50, 26) Unresolved reference: date  
Error:(51, 26) Unresolved reference: description  
Error:(52, 26) Unresolved reference: maxTemperature  
Error:(53, 26) Unresolved reference: minTemperature  
Error:Execution failed for task ‘:app:compileDebugKotlin’.

> Compilation error. See log for more details  
> Information:BUILD FAILED  
> Information:Total time: 3.816 secs  
> Information:21 errors  
> Information:0 warnings  
> Information:See complete output in console

---

<div class="post-metadata">

**Author:** ![watsonyao](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/watsonyao/32/1823_2.png) [@watsonyao](https://discuss.kotlinlang.org/u/watsonyao)\
**Post date:** [February 19, 2016, 3:27am UTC](https://discuss.kotlinlang.org/t/kotlin-for-android-developers-demo-can-not-run-any-more-in-as-beta-5/1482/2 "2016-02-19T03:27:51Z")

</div>

i miss the below code:  
buildscript {  
repositories {  
jcenter()  
}  
dependencies {  
classpath “org.jetbrains.kotlin:kotlin-android-extensions:$kotlin\_version”  
}  
}

when i fix the code:  
the demo app show nothing in the activity,  
and the logcat show below:  
02-19 11:26:18.749 12124-12124/com.antonioleiva.weatherapp E/RecyclerView: No adapter attached; skipping layout  
02-19 11:26:18.759 12124-12124/com.antonioleiva.weatherapp E/RecyclerView: No adapter attached; skipping layout

---

<div class="post-metadata">

**Author:** ![watsonyao](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/watsonyao/32/1823_2.png) [@watsonyao](https://discuss.kotlinlang.org/u/watsonyao)\
**Post date:** [April 11, 2016, 10:44am UTC](https://discuss.kotlinlang.org/t/kotlin-for-android-developers-demo-can-not-run-any-more-in-as-beta-5/1482/3 "2016-04-11T10:44:19Z")

</div>

When run in AS 2.0 stable version, it goes OK ~:sunglasses:
