Skip to content

Conversation

koji-1009
Copy link
Contributor

@koji-1009 koji-1009 commented Apr 8, 2023

Fixes flutter/flutter#113819

Fix ShellRoute's sub routes to log output when debugLogDiagnostics is true.
In example/lib/shell_route.dart, the following log is output.

[GoRouter] Full paths for routes:
             => /a
             =>   /a/details
             => /b
             =>   /b/details
             => /c
             =>   /c/details

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the relevant style guides and ran the auto-formatter. (Unlike the flutter/flutter repo, the flutter/packages repo does use dart format.)
  • I signed the CLA.
  • The title of the PR starts with the name of the package surrounded by square brackets, e.g. [shared_preferences]
  • I listed at least one issue that this PR fixes in the description above.
  • I updated pubspec.yaml with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.
  • I updated CHANGELOG.md to add a description of the change, following repository CHANGELOG style.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@koji-1009 koji-1009 requested a review from chunhtai as a code owner April 8, 2023 09:14
@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat (don't just cc him here, he won't see it! He's on Discord!).

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.

@koji-1009 koji-1009 force-pushed the show_shell_route_routes_in_debug_log branch from 4ab7871 to 1666e48 Compare April 8, 2023 09:18
@koji-1009 koji-1009 force-pushed the show_shell_route_routes_in_debug_log branch from 5d0c5fc to 86e1e14 Compare April 10, 2023 14:02
@@ -172,7 +172,9 @@ class RouteConfiguration {
return 'RouterConfiguration: $routes';
}

String _debugKnownRoutes() {
/// Returns full paths of all routes and known full paths of route names.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's known full paths of route names. Can you make it more clear?

koji-1009 and others added 2 commits April 11, 2023 08:21
Co-authored-by: chunhtai <47866232+chunhtai@users.noreply.github.com>
@koji-1009 koji-1009 requested a review from chunhtai April 11, 2023 11:11
Copy link
Contributor

@chunhtai chunhtai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chunhtai chunhtai requested a review from johnpryan April 11, 2023 16:08
Co-authored-by: chunhtai <47866232+chunhtai@users.noreply.github.com>
Copy link
Contributor

@chunhtai chunhtai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry i missed this one, this should be the last one

@chunhtai chunhtai added the autosubmit Merge PR when tree becomes green via auto submit App label Apr 12, 2023
@auto-submit auto-submit bot merged commit f747441 into flutter:main Apr 12, 2023
@koji-1009 koji-1009 deleted the show_shell_route_routes_in_debug_log branch April 12, 2023 15:48
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Apr 13, 2023
nploi pushed a commit to nploi/packages that referenced this pull request Jul 16, 2023
[go_router]Show ShellRoute's routes in debug log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autosubmit Merge PR when tree becomes green via auto submit App needs tests p: go_router
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[go_router] ShellRoute sub routes not shown in debugLogDiagnostics log
3 participants