“'this' is not available” in debug windows of Android Studio

最后都变了- 提交于 2019-12-02 17:43:42

问题


Please I really need help with this,

this might seem a duplicate of "'this' is not available" in debug windows of Android Studio

but I need to provide more information to address the specific issue.

So I am in the same situation of the question at the link, but I suspect that it has to do with my build setup.

Please help.


This is my build.gradle:

buildscript {
repositories {
    maven { url 'http://download.crashlytics.com/maven' }
    mavenCentral()

}

dependencies {
    classpath 'com.crashlytics.tools.gradle:crashlytics-gradle:1.+'
    classpath 'com.jakewharton.hugo:hugo-plugin:1.2.1'
}
}
apply plugin: 'com.android.application'
apply plugin: 'crashlytics'
apply plugin: 'com.jakewharton.hugo'

repositories {
maven { url 'http://download.crashlytics.com/maven' }
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
maven { url "https://jitpack.io" }
maven { url 'https://dl.bintray.com/kennyc1012/maven' }
}

android {
compileSdkVersion 23
buildToolsVersion "23.0.1"

defaultConfig {
    applicationId "com.foo"
    minSdkVersion 16
    targetSdkVersion 21
    versionCode 21
    versionName "4.7"
}

buildTypes {
    debug {
        debuggable true
    }
   }

packagingOptions {
    exclude 'META-INF/notice.txt'
    exclude 'META-INF/license.txt'
    exclude 'META-INF/LICENSE.txt'
    exclude 'META-INF/NOTICE.txt'
    exclude 'LICENSE.txt'
    exclude 'META-INF/maven/com.squareup.okhttp/okhttp/pom.xml'
    exclude 'META-INF/maven/com.squareup.okhttp/okhttp/pom.properties'
}
}

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile 'junit:junit:4.12'
androidTestCompile 'org.hamcrest:hamcrest-library:1.3'
compile('com.squareup.retrofit:converter-simplexml:2.0.0-beta2') {
    exclude module: 'xpp3'
    exclude group: 'stax'
}
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:preference-v7:23.1.1'
compile 'com.android.support:palette-v7:23.1.1'
compile 'com.android.support:recyclerview-v7:23.1.1'
compile 'com.android.support:cardview-v7:23.1.1'
compile 'com.octo.android.robospice:robospice-spring-android:1.4.14'
compile 'org.codehaus.jackson:jackson-core-asl:1.9.13'
compile 'com.octo.android.robospice:robospice-ui-spicelist:1.4.14'
compile 'com.crashlytics.android:crashlytics:1.+'
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.3'
compile 'org.jsoup:jsoup:1.7.2'
compile 'com.ToxicBakery.viewpager.transforms:view-pager-transforms:1.1.0@aar'
compile 'com.astuetz:pagerslidingtabstrip:1.0.1'
compile 'com.getbase:floatingactionbutton:1.9.0'
compile 'com.android.support:design:23.1.1'
compile 'joda-time:joda-time:2.9.1'
compile 'com.squareup.okhttp:logging-interceptor:2.6.0'
compile 'com.android.support:support-v4:23.1.1'
compile 'com.jayway.android.robotium:robotium-solo:5.5.3'
compile 'com.kennyc:multistateview:1.1'
compile 'com.mikepenz:iconics-core:2.5.2@aar'
compile 'com.mikepenz:fontawesome-typeface:4.5.0.1@aar'
compile 'com.mikepenz:google-material-typeface:2.1.0.1.original@aar'
compile 'me.henrytao:smooth-app-bar-layout:1.0.1'
compile 'fr.avianey.com.viewpagerindicator:library:2.4.1.1@aar'
compile 'com.google.android.gms:play-services-appindexing:8.1.0'
}

this is the top level build.gradle

buildscript {
repositories {
    jcenter()
}
dependencies {
    classpath 'com.android.tools.build:gradle:1.5.0'
}
}

allprojects {
repositories {
    jcenter()
}
}

回答1:


Just remove Hugo, and the problem will be solved. This issue is duplicated and as been already answer in the following post : "'this' is not available" in debug windows of Android Studio

A issue has been published to the Hugo repo.




回答2:


I meet the same question.Try this method:make your build.gradle have---------> minifyEnabled false. Sometime i use this way resolve my problem.



来源:https://stackoverflow.com/questions/35816685/this-is-not-available-in-debug-windows-of-android-studio

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!