• 8
name

A PHP Error was encountered

Severity: Notice

Message: Undefined index: userid

Filename: views/question.php

Line Number: 191

Backtrace:

File: /home/prodcxja/public_html/questions/application/views/question.php
Line: 191
Function: _error_handler

File: /home/prodcxja/public_html/questions/application/controllers/Questions.php
Line: 433
Function: view

File: /home/prodcxja/public_html/questions/index.php
Line: 315
Function: require_once

I'm building a Gradle plugin with Kotlin that compiles against the Android build tools so I can use the Android Transform API, and also get Android build configuration at runtime from the Android plugin. I've had no problems with this configurations so far:

apply plugin: 'java-gradle-plugin'
apply plugin: 'kotlin'
apply plugin: 'maven'

repositories {
    google()
    jcenter()
}

dependencies {
    implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"

    implementation 'commons-io:commons-io:2.6'
    implementation 'org.ow2.asm:asm:7.0'

    compileOnly gradleApi()
    compileOnly('com.android.tools.build:gradle:3.2.1') {
        exclude group: 'org.jetbrains.kotlin'
    }
}

compileKotlin {
    kotlinOptions {
        jvmTarget = "1.8"
    }
}
compileTestKotlin {
    kotlinOptions {
        jvmTarget = "1.8"
    }
}

Note that I have to exclude Kotlin transitive dependencies from the Android build tools library, or possibly get Kotlin version warnings. And this is just fine.

However, when I upgrade the Android build tools to 3.3.0, I get this warning during the Gradle build:

w: Some JAR files in the classpath have the Kotlin Runtime library bundled into them. This may cause difficult to debug problems if there's a different version of the Kotlin Runtime library in the classpath. Consider removing these libraries from the classpath

w: /path/to/.gradle/caches/modules-2/files-2.1/com.android.tools.build/builder/3.3.0/de1cc306a8a198f59d56cb9a909d9a4f516116e7/builder-3.3.0.jar: Library has Kotlin runtime bundled into it

This warning doesn't seem to pose any problems in practice (everything still builds and runs OK), but obviously I don't like having the warning there, and I don't know what's causing it. When I view the dependency tree, I don't even see any bundled Kotlin libraries that don't come from my own declaration:

compileClasspath - Compile classpath for compilation 'main' (target  (jvm)).
+--- com.android.tools.build:gradle:3.3.0
|    +--- com.android.tools.build:builder:3.3.0
|    |    +--- com.android.tools.build:builder-model:3.3.0
|    |    |    \--- com.android.tools:annotations:26.3.0
|    |    +--- com.android.tools.build:builder-test-api:3.3.0
|    |    |    \--- com.android.tools.ddms:ddmlib:26.3.0
|    |    |         +--- com.android.tools:common:26.3.0
|    |    |         |    +--- com.android.tools:annotations:26.3.0
|    |    |         |    \--- com.google.guava:guava:26.0-jre
|    |    |         |         +--- com.google.code.findbugs:jsr305:3.0.2
|    |    |         |         +--- org.checkerframework:checker-qual:2.5.2
|    |    |         |         +--- com.google.errorprone:error_prone_annotations:2.1.3 -> 2.2.0
|    |    |         |         +--- com.google.j2objc:j2objc-annotations:1.1
|    |    |         |         \--- org.codehaus.mojo:animal-sniffer-annotations:1.14
|    |    |         \--- net.sf.kxml:kxml2:2.3.0
|    |    +--- com.android.tools:sdklib:26.3.0
|    |    |    +--- com.android.tools.layoutlib:layoutlib-api:26.3.0
|    |    |    |    +--- com.android.tools:common:26.3.0 (*)
|    |    |    |    +--- net.sf.kxml:kxml2:2.3.0
|    |    |    |    +--- com.android.tools:annotations:26.3.0
|    |    |    |    \--- org.jetbrains:annotations:13.0
|    |    |    +--- com.android.tools:dvlib:26.3.0
|    |    |    |    \--- com.android.tools:common:26.3.0 (*)
|    |    |    +--- com.android.tools:repository:26.3.0
|    |    |    |    +--- com.android.tools:common:26.3.0 (*)
|    |    |    |    +--- com.sun.activation:javax.activation:1.2.0
|    |    |    |    +--- org.apache.commons:commons-compress:1.12
|    |    |    |    +--- org.glassfish.jaxb:jaxb-runtime:2.2.11
|    |    |    |    |    +--- org.glassfish.jaxb:jaxb-core:2.2.11
|    |    |    |    |    |    +--- javax.xml.bind:jaxb-api:2.2.12-b140109.1041
|    |    |    |    |    |    +--- org.glassfish.jaxb:txw2:2.2.11
|    |    |    |    |    |    \--- com.sun.istack:istack-commons-runtime:2.21
|    |    |    |    |    +--- org.jvnet.staxex:stax-ex:1.7.7
|    |    |    |    |    \--- com.sun.xml.fastinfoset:FastInfoset:1.2.13
|    |    |    |    \--- com.google.jimfs:jimfs:1.1
|    |    |    |         \--- com.google.guava:guava:18.0 -> 26.0-jre (*)
|    |    |    +--- com.google.code.gson:gson:2.8.0
|    |    |    +--- org.apache.commons:commons-compress:1.12
|    |    |    +--- org.apache.httpcomponents:httpmime:4.5.2
|    |    |    |    \--- org.apache.httpcomponents:httpclient:4.5.2
|    |    |    |         +--- org.apache.httpcomponents:httpcore:4.4.4 -> 4.4.5
|    |    |    |         +--- commons-logging:commons-logging:1.2
|    |    |    |         \--- commons-codec:commons-codec:1.9
|    |    |    \--- org.apache.httpcomponents:httpcore:4.4.5
|    |    +--- com.android.tools:sdk-common:26.3.0
|    |    |    +--- com.android.tools:sdklib:26.3.0 (*)
|    |    |    +--- com.android.tools.build:builder-test-api:3.3.0 (*)
|    |    |    +--- com.android.tools.build:builder-model:3.3.0 (*)
|    |    |    +--- com.android.tools.ddms:ddmlib:26.3.0 (*)
|    |    |    +--- org.bouncycastle:bcpkix-jdk15on:1.56
|    |    |    |    \--- org.bouncycastle:bcprov-jdk15on:1.56
|    |    |    +--- org.bouncycastle:bcprov-jdk15on:1.56
|    |    |    +--- com.google.protobuf:protobuf-java:3.4.0
|    |    |    \--- javax.inject:javax.inject:1
|    |    +--- com.android.tools:common:26.3.0 (*)
|    |    +--- com.android.tools.build:manifest-merger:26.3.0
|    |    |    +--- com.android.tools:common:26.3.0 (*)
|    |    |    +--- com.android.tools:sdklib:26.3.0 (*)
|    |    |    +--- com.android.tools:sdk-common:26.3.0 (*)
|    |    |    +--- com.google.code.gson:gson:2.8.0
|    |    |    \--- net.sf.kxml:kxml2:2.3.0
|    |    +--- com.android.tools.ddms:ddmlib:26.3.0 (*)
|    |    +--- com.android.tools.analytics-library:protos:26.3.0
|    |    |    \--- com.google.protobuf:protobuf-java:3.4.0
|    |    +--- com.android.tools.analytics-library:shared:26.3.0
|    |    |    +--- com.android.tools.analytics-library:protos:26.3.0 (*)
|    |    |    +--- com.android.tools:annotations:26.3.0
|    |    |    +--- com.android.tools:common:26.3.0 (*)
|    |    |    +--- com.google.guava:guava:26.0-jre (*)
|    |    |    \--- com.google.code.gson:gson:2.8.0
|    |    +--- com.android.tools.analytics-library:tracker:26.3.0
|    |    |    +--- com.android.tools:annotations:26.3.0
|    |    |    +--- com.android.tools:common:26.3.0 (*)
|    |    |    +--- com.android.tools.analytics-library:protos:26.3.0 (*)
|    |    |    +--- com.android.tools.analytics-library:shared:26.3.0 (*)
|    |    |    +--- com.google.protobuf:protobuf-java:3.4.0
|    |    |    \--- com.google.guava:guava:26.0-jre (*)
|    |    +--- com.android.tools.build:apksig:3.3.0
|    |    +--- com.android.tools.build:apkzlib:3.3.0
|    |    |    +--- com.google.code.findbugs:jsr305:1.3.9 -> 3.0.2
|    |    |    +--- com.google.guava:guava:23.0 -> 26.0-jre (*)
|    |    |    +--- org.bouncycastle:bcpkix-jdk15on:1.56 (*)
|    |    |    +--- org.bouncycastle:bcprov-jdk15on:1.56
|    |    |    \--- com.android.tools.build:apksig:3.3.0
|    |    +--- com.squareup:javawriter:2.5.0
|    |    +--- org.bouncycastle:bcpkix-jdk15on:1.56 (*)
|    |    +--- org.bouncycastle:bcprov-jdk15on:1.56
|    |    +--- org.ow2.asm:asm:6.0 -> 7.0
|    |    +--- org.ow2.asm:asm-tree:6.0
|    |    |    \--- org.ow2.asm:asm:6.0 -> 7.0
|    |    +--- org.ow2.asm:asm-commons:6.0
|    |    |    \--- org.ow2.asm:asm-tree:6.0 (*)
|    |    +--- org.ow2.asm:asm-util:6.0
|    |    |    \--- org.ow2.asm:asm-tree:6.0 (*)
|    |    +--- it.unimi.dsi:fastutil:7.2.0
|    |    +--- net.sf.jopt-simple:jopt-simple:4.9
|    |    \--- com.googlecode.json-simple:json-simple:1.1
|    +--- com.android.tools.analytics-library:shared:26.3.0 (*)
|    +--- com.android.tools.analytics-library:crash:26.3.0
|    |    +--- com.android.tools:annotations:26.3.0
|    |    +--- com.google.guava:guava:26.0-jre (*)
|    |    +--- org.apache.httpcomponents:httpmime:4.5.2 (*)
|    |    +--- org.apache.httpcomponents:httpcore:4.4.5
|    |    \--- org.apache.httpcomponents:httpclient:4.5.2 (*)
|    +--- com.android.tools.lint:lint-gradle-api:26.3.0
|    |    +--- com.android.tools:sdklib:26.3.0 (*)
|    |    +--- com.android.tools.build:builder-model:3.3.0 (*)
|    |    +--- com.android.tools.build:gradle-api:3.3.0
|    |    |    +--- com.android.tools.build:builder-model:3.3.0 (*)
|    |    |    +--- com.android.tools.build:builder-test-api:3.3.0 (*)
|    |    |    \--- com.google.guava:guava:26.0-jre (*)
|    |    \--- com.google.guava:guava:26.0-jre (*)
|    +--- com.android.tools.build:gradle-api:3.3.0 (*)
|    +--- androidx.databinding:databinding-compiler-common:3.3.0
|    |    +--- androidx.databinding:databinding-common:3.3.0
|    |    +--- com.android.databinding:baseLibrary:3.3.0
|    |    +--- org.antlr:antlr4:4.5.3
|    |    +--- commons-io:commons-io:2.4 -> 2.6
|    |    +--- com.googlecode.juniversalchardet:juniversalchardet:1.0.3
|    |    +--- com.google.guava:guava:26.0-jre (*)
|    |    +--- com.squareup:javapoet:1.8.0
|    |    +--- com.google.code.gson:gson:2.8.0
|    |    +--- com.android.tools:annotations:26.3.0
|    |    \--- com.android.tools.build.jetifier:jetifier-core:1.0.0-beta02
|    |         \--- com.google.code.gson:gson:2.8.0
|    +--- com.android.tools.build:transform-api:2.0.0-deprecated-use-gradle-api
|    +--- org.ow2.asm:asm:6.0 -> 7.0
|    +--- org.ow2.asm:asm-analysis:6.0
|    |    \--- org.ow2.asm:asm-tree:6.0 (*)
|    +--- org.ow2.asm:asm-commons:6.0 (*)
|    +--- org.ow2.asm:asm-util:6.0 (*)
|    +--- net.sf.jopt-simple:jopt-simple:4.9
|    +--- net.sf.proguard:proguard-gradle:6.0.3
|    |    \--- net.sf.proguard:proguard-base:6.0.3
|    +--- com.android.tools.build:bundletool:0.6.0
|    |    +--- com.google.auto.value:auto-value:1.5.2
|    |    +--- com.android.tools.build:aapt2-proto:0.3.1
|    |    |    \--- com.google.protobuf:protobuf-java:3.4.0
|    |    +--- com.google.errorprone:error_prone_annotations:2.2.0
|    |    +--- com.google.guava:guava:26.0-jre (*)
|    |    +--- com.google.protobuf:protobuf-java:3.4.0
|    |    \--- com.google.protobuf:protobuf-java-util:3.4.0
|    |         +--- com.google.protobuf:protobuf-java:3.4.0
|    |         +--- com.google.guava:guava:19.0 -> 26.0-jre (*)
|    |         \--- com.google.code.gson:gson:2.7 -> 2.8.0
|    +--- com.android.tools.build.jetifier:jetifier-core:1.0.0-beta02 (*)
|    \--- com.android.tools.build.jetifier:jetifier-processor:1.0.0-beta02
|         +--- org.ow2.asm:asm:6.0 -> 7.0
|         +--- org.ow2.asm:asm-util:6.0 (*)
|         +--- org.ow2.asm:asm-commons:6.0 (*)
|         +--- org.jdom:jdom2:2.0.6
|         \--- com.android.tools.build.jetifier:jetifier-core:1.0.0-beta02 (*)
+--- org.jetbrains.kotlin:kotlin-stdlib:1.3.20
|    +--- org.jetbrains.kotlin:kotlin-stdlib-common:1.3.20
|    \--- org.jetbrains:annotations:13.0
+--- commons-io:commons-io:2.6
\--- org.ow2.asm:asm:7.0

Is there any way to clean up this warning, or am I looking at a bug here?

Gradle version is 5.1.1.