-
-
Notifications
You must be signed in to change notification settings - Fork 66
Use KSP2 #350
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use KSP2 #350
Conversation
kotlin-inject-compiler/ksp/src/main/kotlin/me/tatarka/inject/compiler/ksp/Util.kt
Outdated
Show resolved
Hide resolved
ba8f1eb
to
bbcc6b9
Compare
c2775ad
to
d5e308f
Compare
9f0d6ec
to
ede41bd
Compare
kotlin-inject-compiler/ksp/src/main/kotlin/me/tatarka/inject/compiler/ksp/Util.kt
Outdated
Show resolved
Hide resolved
kotlin-inject-compiler/test/src/main/kotlin/me/tatarka/inject/ProjectCompiler.kt
Outdated
Show resolved
Hide resolved
bb53268
to
009a7e7
Compare
kotlin-inject-compiler/test/src/main/kotlin/me/tatarka/inject/ProjectCompiler.kt
Outdated
Show resolved
Hide resolved
kotlin-inject-compiler/test/src/main/kotlin/me/tatarka/inject/ProjectCompiler.kt
Outdated
Show resolved
Hide resolved
761cad1
to
f52527a
Compare
8fb90a7
to
82ddb23
Compare
@evant I updated all dependencies to latest versions, but looks like google/ksp#1854 is still an issue, as well as some issues with I probably won't have much time to dedicate to this for the next few months, in case there's anyone who'd like to pick it up. |
The exception
whereas the corresponding element of
Please avoid caching and using the elements across rounds. |
Yup, I started working on that. Not sure if I'm doing something wrong because I'm getting other errors but at least the |
@evant I believe the latest commit fixes the There is still an issue with typealiases (probably related to google/ksp#1921). Most of the |
kotlin-inject-compiler/test/src/test/kotlin/me/tatarka/inject/test/FailureTest.kt
Show resolved
Hide resolved
I've seen enough issues that I think it would be good to have overlap supporting both for a bit. What breaks here with ksp1? I don't know if it'll easy to detect which one you are using but we could add an additional option to enable it for now |
Actually it looks like it |
Got some inspiration from https://github.com/amzn/kotlin-inject-anvil/blob/main/compiler-utils/src/testFixtures/kotlin/software/amazon/lastmile/kotlin/inject/anvil/Compilation.kt and figured it out 😄 The only unit tests failing now are the ones that check for a specific error format that changed from KSP1 to KSP2, so I'm thinking that it is fine. |
Updated the unit and integration tests to run with both KSP1 and KSP2. |
looks like it's already fixed! I'm ok with throwing a clean on ci for now until that's released though |
Updated, hopefully that's all that's needed. |
- Avoids issues until google/ksp#2231 is released
@evant anything still needed here (aside from getting past New Years)? |
Will take a final pass when I get a chance but don't imagine anything major blocking merge, no |
It looks like function injection isn't working where the typealias points to another typealias. I don't have the time to investigate now, but that wasn't working before these changes either, so I'm guessing not a blocker? |
yeah, if it's not a regression it's not a blocker |
kotlin-inject-compiler/core/src/main/kotlin/me/tatarka/inject/compiler/Util.kt
Outdated
Show resolved
Hide resolved
kotlin-inject-compiler/test/src/test/kotlin/me/tatarka/inject/test/InheritanceTest.kt
Outdated
Show resolved
Hide resolved
@evant with KSP 2.0.0 enabling KSP2 by default, can we get a release that includes this? |
No description provided.