Status Update
Comments
vi...@google.com <vi...@google.com>
vi...@google.com <vi...@google.com>
yb...@google.com <yb...@google.com> #2
For Kotlin 2.0 and KSP 2.0 the Cannot change attributes of configuration ':composeApp:debugFrameworkIosX64' after it has been locked for mutation
really seems like a KSP issue. You should file a bug in their repository with a sample app if possible.
If you downgrade to Kotlin 1.9 then things 'should' work, there are example apps out there with such configuration, like the following one:
he...@gmail.com <he...@gmail.com> #3
Will try to use the example provided by you to check if it fixes the issue.
yb...@google.com <yb...@google.com> #4
Note that this issue happens when applying the Compose, KSP and Room Plugin together in Kotlin 2.0.x, the workaround for now is to not use the Room Gradle Plugin and instead specify the schema location vis KSP arguments:
// In the build.gradle
ksp {
arg("room.schemaLocation", "${projectDir}/schemas")
}
he...@gmail.com <he...@gmail.com> #5
Hi, I encountered a similar problem and was able to resolve it by updating the dependencies
room = "2.7.0-alpha08"
ksp = "2.0.20-1.0.25"
compose-plugin = "1.6.11"
kotlin = "2.0.20"
ap...@google.com <ap...@google.com> #6
Branch: androidx-master-dev
commit d917ca679e490655042b08397c379997634c61ce
Author: Jeff Gaston <jeffrygaston@google.com>
Date: Thu Mar 19 12:16:36 2020
Having androidx.sh check for duplicate output files before building
rather than after. When multiple tasks have the same output, errors messages are really confusing.
Bug: 150106190
Test: treehugger runs androidx.sh
Change-Id: I4ee7e26df17a4ad883ad29c5007b4d3748db7099
M busytown/androidx.sh
ap...@google.com <ap...@google.com> #7
Branch: androidx-master-dev
commit c96fb26024f5125484d6f80eca05d570055deb53
Author: Yigit Boyar <yboyar@google.com>
Date: Mon Mar 16 17:22:40 2020
Add shadow plugin to prebuilts
This plugin allows us to jarjar dependencies that might conflict with others.
Bug: 150106190
Test: n/a
Change-Id: I0f344313b27d6ba6e1273142a721dad254124705
A com/github/jengelman/gradle/plugins/shadow/5.2.0/LICENSE
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0-sources.jar
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0-sources.jar.md5
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0-sources.jar.sha1
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0.jar
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0.jar.md5
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0.jar.sha1
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0.pom
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0.pom.md5
A com/github/jengelman/gradle/plugins/shadow/5.2.0/shadow-5.2.0.pom.sha1
ap...@google.com <ap...@google.com> #8
Branch: androidx-master-dev
commit 562a37df135f25e77f9103f695308d3945c2e2c7
Author: Yigit Boyar <yboyar@google.com>
Date: Mon Mar 16 13:00:36 2020
Shadow Room's antlr dependency
Anltr runtime does a version check between itself and generated
code and might print a warning if they don't match.
To be safe, Room compiler jarjar's its Antlr dependency so that
it cannot conflict with other annotation processors which might
also use antlr (e.g. data binding)
To ensure it does not break, I've added a verification task to
Room compiler module and also added it as a dependeny to the
buildOnServer task.
The task checks the generated pom for room-compiler to make sure
it does not include antlr but it includes at least one another
dependency (kotlin-stdlib).
I've also added checks for the room-compiler-jar contents to double
check antlr is there and its package is moved.
Bug: 150106190
Test: buildOnServer verifies the output
Change-Id: I2c99cba0b3b42369a4b495e5c086f18f5d0b3bff
M build.gradle
M buildSrc/src/main/kotlin/androidx/build/dependencies/Dependencies.kt
M buildSrc/src/main/kotlin/androidx/build/uptodatedness/TaskUpToDateValidator.kt
M room/benchmark/build.gradle
M room/compiler/build.gradle
M room/integration-tests/autovaluetestapp/build.gradle
M room/integration-tests/kotlintestapp/build.gradle
M room/integration-tests/noappcompattestapp/build.gradle
M room/integration-tests/testapp/build.gradle
yb...@google.com <yb...@google.com>
it...@gmail.com <it...@gmail.com> #9
yb...@google.com <yb...@google.com> #10
it is only on master, this might take a while to release as we'll probably make a minor version bump and an alpha to ensure it works fine.
meanwhile, you can try it via:
Room master is fairly stable so there is less risk in using its snapshots (but of course, they are snapshots so there is some risk of instability :) )
Description
ANTLR Tool version 4.5.3 used for code generation does not match the current runtime version 4.7.1ANTLR Runtime version 4.5.3 used for parser compilation does not match the current runtime version 4.7.1ANTLR Tool version 4.5.3 used for code generation does not match the current runtime version 4.7.1ANTLR Runtime version 4.5.3 used for parser compilation does not match the current runtime version 4.7.1error: cannot generate view binders java.lang.StackOverflowError
And then a list of calls that caused the java.lang.StackOverflowError
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:209)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211)
at android.databinding.tool.expr.Expr.resolveListeners(Expr.java:211) (etc)
It seems that it is known issue with data binding and room mismatch from what I read online but the solution of forcing a particular version of antlr4 doesn't work for me.
When forcing a version of antlr4 like so
configurations.all() {
resolutionStrategy.force "org.antlr:antlr4-runtime:4.5.3"
resolutionStrategy.force "org.antlr:antlr4-tool:4.5.3"
}
I can;'t compile Room with error Caused by: java.lang.ClassNotFoundException: org.antlr.v4.runtime.CharStreams
when forcing it to 4.7.1 it does nothing. Same error with version mismatch. Downgrading Room does nothing.