-
Notifications
You must be signed in to change notification settings - Fork 404
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
Add support for KSP #323
Add support for KSP #323
Conversation
…v:kotlin-compile-testing for testing. Moved all tests over and make them more meaningful by testing what ends up in the index instad of just 1:1 ow which code they generate) which with the index bing binary is unverifiable.
Removed old unused dependencies Check generated source on top of functionality Split method and class elements into two sets for processing Fixed index generation for inner classes Added processor test with inner class Enabled ksp for sample project
Fix originalting elment for Registry generation. Made unit test when running via ksp not to compiled code check.
Fix warning Updated gradle to 7.1
Clean up gralde plugin dependency for ksp. Updated documentation.
Remove airbnb repo dependency
Also add ktlint to ci checks.
…et the custom processors from config. Use testKsp to test that behavior.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome - thanks for all the Koltin conversions, setting up ktlint and mockk! I'll take a look at the inner class error and see if I have any insight
...linkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/DeepLinkAnnotatedElement.kt
Outdated
Show resolved
Hide resolved
deeplinkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/DeepLinkProcessor.kt
Outdated
Show resolved
Hide resolved
|
||
```groovy | ||
ksp { | ||
arg("deepLink.incremental", "true") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do you feel about removing the non incremental option? Looking through this PR, it would reduces complexity, and really everyone should want to use incremental.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just wanted to keep it backwards compatible. It would imho not reduce complexity by that much. But it can be on the chopping block if it does not fit with any other major changes.
deeplinkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/DeepLinkProcessor.kt
Outdated
Show resolved
Hide resolved
deeplinkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/DeepLinkProcessor.kt
Show resolved
Hide resolved
deeplinkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/Documentor.kt
Outdated
Show resolved
Hide resolved
deeplinkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/Documentor.kt
Show resolved
Hide resolved
...inkdispatch-processor/src/test/java/com/airbnb/deeplinkdispatch/BaseDeepLinkProcessorTest.kt
Outdated
Show resolved
Hide resolved
deeplinkdispatch-processor/src/main/java/com/airbnb/deeplinkdispatch/DeepLinkProcessor.kt
Show resolved
Hide resolved
@BenSchwab I created an issue ticket with ksp here google/ksp#492 for the inner class error. |
Adde Kotlin source base tests. Cleanup/fixes
… done for room (mentioned here tschuchortdev/kotlin-compile-testing#105 (comment)) but this also does not work. Disabled ksp test for inner classes in java because of tschuchortdev/kotlin-compile-testing#105
Add Kotlin based module
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
README.md
Outdated
|
||
When using Kotlin we strongly suggest to use KSP as it can bring major speed improvements. | ||
We ran into issues when enabling KSP on a project while the Kapt plugin was still applied. | ||
If you want to both use Kapt and KSP processors on the same project be careful and expect |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder how much of this was just caused by the no java sources issues - Eli talked a bit more to the KSP team, and running both kapt and ksp should be fine, so long as no kapt processor depends on the ksp generated sources
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I wanted to remove this actually, thx for pointing it out.
Added support for KSP (https://github.com/google/ksp) via Rooms XProcessing library (https://github.com/androidx/androidx/tree/androidx-main/room/room-compiler-processing) as so we can still support kapt and java annotation processor.
Note: The tests are currently failing as there is a bug that causes issues with sub classes right now, still investigating this.
Few other changes: