-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Migrate codebase to Navigation 3 #1902
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
base: main
Are you sure you want to change the base?
Conversation
app/src/main/kotlin/com/google/samples/apps/nowinandroid/di/BackStackProvider.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/google/samples/apps/nowinandroid/di/BackStackProvider.kt
Outdated
Show resolved
Hide resolved
...n/com/google/samples/apps/nowinandroid/feature/search/impl/navigation/SearchEntryProvider.kt
Outdated
Show resolved
Hide resolved
...n/com/google/samples/apps/nowinandroid/feature/search/impl/navigation/SearchEntryProvider.kt
Outdated
Show resolved
Hide resolved
feature/topic/api/src/main/res/drawable/feature_topic_api_ic_topic_placeholder.xml
Outdated
Show resolved
Hide resolved
...lin/com/google/samples/apps/nowinandroid/feature/topic/impl/navigation/TopicEntryProvider.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/google/samples/apps/nowinandroid/navigation/NiaNavDisplay.kt
Show resolved
Hide resolved
9b9cfe5
to
b85823d
Compare
...n/com/google/samples/apps/nowinandroid/feature/search/impl/navigation/SearchEntryProvider.kt
Show resolved
Hide resolved
b85823d
to
ce87666
Compare
ba573cc
to
2ab0dde
Compare
2ab0dde
to
f75b028
Compare
app/src/main/kotlin/com/google/samples/apps/nowinandroid/di/BackStackProvider.kt
Show resolved
Hide resolved
app/src/main/kotlin/com/google/samples/apps/nowinandroid/ui/NiaApp.kt
Outdated
Show resolved
Hide resolved
app/src/testDemo/kotlin/com/google/samples/apps/nowinandroid/ui/TestUtil.kt
Outdated
Show resolved
Hide resolved
f75b028
to
0b7f506
Compare
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 think this is redundant can be deleted. IIRC when I ran the dependency graph generation script I excluded the benchmarks
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.
Here's the command I use:
./generateModuleGraphs.sh --exclude-module :benchmarks --exclude-module :lint --exclude-module :ui-test-hilt-manifest
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.
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 did run that particular command but it still generated this. Tried rerunning again after rebasing to main and im getting these errors
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'nowinandroid'.
> Could not create task ':generateModulesGraphvizText'.
> 'org.gradle.api.Project org.gradle.api.artifacts.ProjectDependency.getDependencyProject()'
* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to generate a Build Scan (Powered by Develocity).
> Get more help at https://help.gradle.org.
BUILD FAILED in 983ms
4 actionable tasks: 4 up-to-date
Configuration cache entry stored.
Error: dot: can't open /tmp/dep_graph_core_common.gv: No such file or directory
Done in 1 ms!
0 KiB - NaN% = 0 KiB
rm: /tmp/dep_graph_core_common.gv: No such file or directory
Parallel Configuration Cache is an incubating feature.
Calculating task graph as no cached configuration is available for tasks: generateModulesGraphvizText
Type-safe project accessors is an incubating feature.
The newly generated svg graphs are not showing properly as a result. Any idea what may be causing this?
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.
@SimonMarquis Thanks for bringing this up again. I agree this would be a great time to implement this change. I added some comments to #1554
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.
@claraf3 Could it be that your /tmp
folder isn't world writeable? What happens when you run the following command?
./gradlew generateModulesGraphvizText -Pmodules.graph.output.gv="/tmp/dep_graph_core_common.gv" -Pmodules.graph.of.module=":core:common"
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 get the same error as above
> Could not create task ':generateModulesGraphvizText'.
> 'org.gradle.api.Project org.gradle.api.artifacts.ProjectDependency.getDependencyProject()'
It happens on main branch for me too. Are you able to replicate this locally?
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.
@claraf3 Did you check if /tmp
was world writeable? What if you try ./gradlew generateModulesGraphvizText -Pmodules.graph.output.gv="~/dep_graph_core_common.gv" -Pmodules.graph.of.module=":core:common"
?
benchmarks/README.md
Outdated
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.
We can exclude this one
build-logic/convention/src/main/kotlin/AndroidFeatureApiConventionPlugin.kt
Show resolved
Hide resolved
build-logic/convention/src/main/kotlin/AndroidFeatureApiConventionPlugin.kt
Outdated
Show resolved
Hide resolved
...ic/api/src/main/kotlin/com/google/samples/apps/nowinandroid/feature/topic/api/TopicScreen.kt
Outdated
Show resolved
Hide resolved
...api/src/main/kotlin/com/google/samples/apps/nowinandroid/feature/topic/api/TopicViewModel.kt
Outdated
Show resolved
Hide resolved
...main/kotlin/com/google/samples/apps/nowinandroid/feature/topic/api/TopicDetailPlaceholder.kt
Outdated
Show resolved
Hide resolved
Source code is still left in api module. impl module is empty at this point.
Bump agp versions and add navigation 3 dependency
f87e507
to
08f9dd0
Compare
Is there a |
|
...ogle/samples/apps/nowinandroid/feature/foryou/impl/navigation/ForYouRouteSerializerModule.kt
Outdated
Show resolved
Hide resolved
...gle/samples/apps/nowinandroid/feature/bookmarks/impl/navigation/BookmarksSerializerModule.kt
Outdated
Show resolved
Hide resolved
08f9dd0
to
289d1ac
Compare
c894a90
to
42dd8fc
Compare
42dd8fc
to
e9c54a8
Compare
[WIP] This PR migrates the codebase to using Jetpack Navigation 3.
More details to follow...