Skip to content

[pigeon] Adds package name to method channel. #4443

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

Merged
merged 2 commits into from
Jul 21, 2023

Conversation

tarrinneal
Copy link
Contributor

@tarrinneal tarrinneal commented Jul 11, 2023

Adds package name to method channel name strings. The name can be added via command line, pigeon configuration, or automatically using deducePackageName.

This pr also changes the generate function to format by default and adds an n command to not format if needed.

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.

@tarrinneal
Copy link
Contributor Author

broke up the commits to make reviewing easier.

Copy link
Contributor

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

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

LGTM (with one question).

I hadn't thought through quite how much boilerplate plumbing my suggestion would involve, sorry :( If we ever have to do something like this again, we should probably add an internal-facing context object to contain these kinds of params.

@tarrinneal
Copy link
Contributor Author

I hadn't thought through quite how much boilerplate plumbing my suggestion would involve, sorry :( If we ever have to do something like this again, we should probably add an internal-facing context object to contain these kinds of params.

It's not too late to make this change.

@stuartmorgan-g
Copy link
Contributor

stuartmorgan-g commented Jul 20, 2023

I don't think we gain much by doing it now, since we only have one param. It'll be the same work to do later as to do it now, and while doing it now would mean we wouldn't forget, we also might never need a second param. Entirely up to you.

I didn't mean in this pr, but in the future.

@tarrinneal
Copy link
Contributor Author

@stuartmorgan thoughts on the javaOptions.package and kotlinOptions.package params? Should they be removed or deprecated (or nothing)? I didn't want to assume that replacing them with the new system would be good for everyone.

@stuartmorgan-g
Copy link
Contributor

Dart package and Java/Kotlin package are orthogonal, so we should definitely not remove the latter. We may want to rename the parameter for the former dartPackage to avoid confusion.

@tarrinneal tarrinneal added the autosubmit Merge PR when tree becomes green via auto submit App label Jul 21, 2023
@auto-submit auto-submit bot merged commit caabb6f into flutter:main Jul 21, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 24, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 24, 2023
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Jul 24, 2023
flutter/packages@2266a76...8028caf

2023-07-24 [email protected] Roll Flutter from a8c8c55 to d7ed5dc (7 revisions) (flutter/packages#4556)
2023-07-23 [email protected] Roll Flutter from e8b397c to a8c8c55 (11 revisions) (flutter/packages#4552)
2023-07-22 [email protected] Roll Flutter from 9cfbf6b to e8b397c (12 revisions) (flutter/packages#4550)
2023-07-21 [email protected] [ci] Clean up except exclusion list (flutter/packages#4547)
2023-07-21 [email protected] [go_router] Replaces uri related properties in GoRouterState (flutter/packages#4392)
2023-07-21 [email protected] [webview_flutter_wkwebview] Updates pigeon version to `10.1.4` (flutter/packages#4548)
2023-07-21 [email protected] [pigeon] Adds package name to method channel. (flutter/packages#4443)
2023-07-21 [email protected] [ci] Migrate remaing unblocked repo checks to LUCI (flutter/packages#4543)
2023-07-21 [email protected] [go_router] Remove unused dependency (flutter/packages#4545)
2023-07-21 [email protected] Roll Flutter from d07e8ae to 9cfbf6b (58 revisions) (flutter/packages#4544)
2023-07-21 [email protected] Adding myself and Michele to AUTHORS (flutter/packages#4527)
2023-07-21 [email protected] [go_router_builder] Removes `path_to_regexp` from the dependencies  (flutter/packages#4524)
2023-07-21 [email protected] [google_maps_flutter_web] Adds options for gesture handling and tilt controls. (flutter/packages#4521)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
LouiseHsu pushed a commit to LouiseHsu/flutter that referenced this pull request Jul 31, 2023
flutter/packages@2266a76...8028caf

2023-07-24 [email protected] Roll Flutter from a8c8c55 to d7ed5dc (7 revisions) (flutter/packages#4556)
2023-07-23 [email protected] Roll Flutter from e8b397c to a8c8c55 (11 revisions) (flutter/packages#4552)
2023-07-22 [email protected] Roll Flutter from 9cfbf6b to e8b397c (12 revisions) (flutter/packages#4550)
2023-07-21 [email protected] [ci] Clean up except exclusion list (flutter/packages#4547)
2023-07-21 [email protected] [go_router] Replaces uri related properties in GoRouterState (flutter/packages#4392)
2023-07-21 [email protected] [webview_flutter_wkwebview] Updates pigeon version to `10.1.4` (flutter/packages#4548)
2023-07-21 [email protected] [pigeon] Adds package name to method channel. (flutter/packages#4443)
2023-07-21 [email protected] [ci] Migrate remaing unblocked repo checks to LUCI (flutter/packages#4543)
2023-07-21 [email protected] [go_router] Remove unused dependency (flutter/packages#4545)
2023-07-21 [email protected] Roll Flutter from d07e8ae to 9cfbf6b (58 revisions) (flutter/packages#4544)
2023-07-21 [email protected] Adding myself and Michele to AUTHORS (flutter/packages#4527)
2023-07-21 [email protected] [go_router_builder] Removes `path_to_regexp` from the dependencies  (flutter/packages#4524)
2023-07-21 [email protected] [google_maps_flutter_web] Adds options for gesture handling and tilt controls. (flutter/packages#4521)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
vashworth pushed a commit to vashworth/flutter that referenced this pull request Aug 2, 2023
flutter/packages@2266a76...8028caf

2023-07-24 [email protected] Roll Flutter from a8c8c55 to d7ed5dc (7 revisions) (flutter/packages#4556)
2023-07-23 [email protected] Roll Flutter from e8b397c to a8c8c55 (11 revisions) (flutter/packages#4552)
2023-07-22 [email protected] Roll Flutter from 9cfbf6b to e8b397c (12 revisions) (flutter/packages#4550)
2023-07-21 [email protected] [ci] Clean up except exclusion list (flutter/packages#4547)
2023-07-21 [email protected] [go_router] Replaces uri related properties in GoRouterState (flutter/packages#4392)
2023-07-21 [email protected] [webview_flutter_wkwebview] Updates pigeon version to `10.1.4` (flutter/packages#4548)
2023-07-21 [email protected] [pigeon] Adds package name to method channel. (flutter/packages#4443)
2023-07-21 [email protected] [ci] Migrate remaing unblocked repo checks to LUCI (flutter/packages#4543)
2023-07-21 [email protected] [go_router] Remove unused dependency (flutter/packages#4545)
2023-07-21 [email protected] Roll Flutter from d07e8ae to 9cfbf6b (58 revisions) (flutter/packages#4544)
2023-07-21 [email protected] Adding myself and Michele to AUTHORS (flutter/packages#4527)
2023-07-21 [email protected] [go_router_builder] Removes `path_to_regexp` from the dependencies  (flutter/packages#4524)
2023-07-21 [email protected] [google_maps_flutter_web] Adds options for gesture handling and tilt controls. (flutter/packages#4521)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants