Status Update
Comments
ad...@google.com <ad...@google.com>
da...@google.com <da...@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:
jl...@gmail.com <jl...@gmail.com> #3
Will try to use the example provided by you to check if it fixes the issue.
da...@google.com <da...@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")
}
jl...@gmail.com <jl...@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 d26e7b29d7b29d77f18a00873ff0446013a0b8ee
Author: Daniel Santiago Rivera <danysantiago@google.com>
Date: Fri Jan 24 08:28:53 2020
Use javax.annotation.processing.Generated on source versions 9+
This changes makes it so that the Room annotation processor generates
code with the right @Generated annotation when the target source
version is 9 or higher.
Bug: 146538330
Test: Manual test since AndroidX is tied to JDK8
Change-Id: Ief247399c347d0970be77cb38f6e22cc48e8faea
M room/compiler/src/main/kotlin/androidx/room/writer/ClassWriter.kt
da...@google.com <da...@google.com>
an...@google.com <an...@google.com> #7
be...@bytedance.com <be...@bytedance.com> #8
kotlin 1.4.0 version
javac 10.0.2
It happened again
Description
I get the error that the @Generated Annotation can not be found because the package javax.annotation does not exist.
CustomerDao_Impl.java:24: error: package javax.annotation does not exist
import javax.annotation.Generated;
CustomerDao_Impl.java:26: error: cannot find symbol
@Generated("androidx.room.RoomProcessor")
This happens when compiling an Android App on Mac OS with
javac --version
javac 10.0.2
I use version 2.1.0 for room-runtime and room-compiler
In Android Studio the app builds fine.
I found a similar issue in Dagger: