Status Update
Comments
to...@gmail.com <to...@gmail.com> #2
sgtm, we can add the same API for FileSpec:
I recommend using github for a small checkout size:
Looks like we do have kotlin poet in the repo:
So just need to add it as an API dependency to the room-compiler-processing's build file.
If you can add a test to the generated code match test, that would be great:
lmk if you hit any blocker in getting started, thanks!
ys...@google.com <ys...@google.com> #3
Branch: androidx-main
commit 4a2360456d817b3101f289aac55ea1f3f610cfef
Author: Gabriel Freitas Vasconcelos <gfreivasc@gmail.com>
Date: Thu Mar 11 14:54:53 2021
[GH] Adds KotlinPoet integration to Room Processing
## Proposed Changes
Adds `write()` method that accepts KotlinPoet's an instance of
`FileSpec`. Also adds KotlinPoet as an API dependency and an extension
function similar to that of JavaPoet.
## Testing
Test: ./gradlew test connectedCheck without benchmarks
## Fixes
Fixes: [
This is an imported pull request from
Resolves #137
Github-Pr-Head-Sha: 96dc315b7e0e417e6a5e3d8cd6a8adda5c1b6c6a
GitOrigin-RevId: c5e4de3ab28fed968982e572c47b5ff07d210af7
Change-Id: I9d3aaa0a752447d9ba3978ce3fb705c0e74b3d13
M room/compiler-processing-testing/src/main/java/androidx/room/compiler/processing/util/CompilationResultSubject.kt
M room/compiler-processing-testing/src/main/java/androidx/room/compiler/processing/util/Source.kt
M room/compiler-processing-testing/src/test/java/androidx/room/compiler/processing/util/GeneratedCodeMatchTest.kt
M room/compiler-processing/build.gradle
M room/compiler-processing/src/main/java/androidx/room/compiler/processing/XFiler.kt
M room/compiler-processing/src/main/java/androidx/room/compiler/processing/javac/JavacFiler.kt
M room/compiler-processing/src/main/java/androidx/room/compiler/processing/javac/JavacProcessingEnv.kt
M room/compiler-processing/src/main/java/androidx/room/compiler/processing/ksp/KspFiler.kt
M room/compiler/src/test/kotlin/androidx/room/testing/test_util.kt
to...@gmail.com <to...@gmail.com> #4
All
aq...@google.com <aq...@google.com> #5
Brining over from dup:
- Note that there's also [Internal ref:
] to convert the resources into vector drawables. We should probably take another look at that first, since it's a lot less disruptive and may make splitting the module unnecessary.b/63761003 - Observation: This is not necessarily true as the ui module might also bring other dependencies (e.g. app compat) that are not necessary in the core module.
- It's highly likely this will be necessary for compose support.
m....@gmail.com <m....@gmail.com> #6
#2 is your fork public?
to...@gmail.com <to...@gmail.com> #7
No because I apply my own formatting rules + ugly workaround for
With that said, on recent versions except the ANR they have fixed all the previous NPE that I workarounded, so building a raw simple fork is easy, delete the ui folder, cleanup res folder and remove all no more needed stuff in build.gradle.
m....@gmail.com <m....@gmail.com> #8
Thanks for the info!
@Google are you open for external contributions, for either the resource migration or the split of mediarouter?
aq...@google.com <aq...@google.com> #9
the resource migration
Are you referring to the migration to drawables? If not can you spell this out?
Aside, I don't think we are in a condition to take contributions for the splitting, because we need to figure out how to ensure we keep a reasonable dependency story, which is something that we need to define ourselves, and probably the most complex bit about this.
I'm sorry we haven't been able to prioritize this so far.
to...@gmail.com <to...@gmail.com> #10
we need to figure out how to ensure we keep a reasonable dependency story,
What do you mean by this ? You can create a mediarouter-core and mediarouter-app (Imo name to define to better reflect and future mediarouter-compose) and just have the current module have transitive usage of the new modules.
The only thing is to split the strings in whatever solution you have for the translations.
m....@gmail.com <m....@gmail.com> #11
Are you referring to the migration to drawables? If not can you spell this out?
Indeed, I was talking about the migration from png to vector drawables, as mentioned in the first point in #5.
m....@gmail.com <m....@gmail.com> #12
I see that there is already a mix of PNGs/vector drawables:
So probably some PNGs can be removed in favor of the corresponding vector drawables, and the rest will need to be replaced with new vector drawables.
Description
Component used: MediaRouter
Version used: 1.2.5
So this is not a bug report but more a feature request or at least a feedback request.
Is there any plans to split MediaRouter into 2 different modules so that the users who do not use UI (.app) part of it are not forced to embed AppCompat and Recyclerview, ... in their final APK for no reason in a full compose world.
In my app this is 300K of unused dex size (15%) not counting all the unwanted ressources too nearly 200K (more than 50% of my resources).