Fixed
Status Update
Comments
vi...@google.com <vi...@google.com>
vi...@google.com <vi...@google.com>
yb...@google.com <yb...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
https://android-review.googlesource.com/1123258
https://goto.google.com/android-sha1/b90079595f33f58fece04026a97faa0d243acdb1
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
he...@gmail.com <he...@gmail.com> #3
yb...@google.com <yb...@google.com> #4
Project: platform/frameworks/support
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically ( b/140759491 ).
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
https://android-review.googlesource.com/1288456
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically (
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
ap...@google.com <ap...@google.com> #6
Project: platform/frameworks/support
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
https://android-review.googlesource.com/1260022
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
Project: platform/prebuilts/androidx/external
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
https://android-review.googlesource.com/1260624
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
Project: platform/frameworks/support
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
https://android-review.googlesource.com/1259721
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
Hi, what is the version this change will be available?
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.