Skip to content
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

Remove deprecated updateSemantics APIs. #37396

Closed

Conversation

a-wallen
Copy link
Contributor

@a-wallen a-wallen commented Nov 7, 2022

fixes flutter/flutter#112221

If you had to change anything in the flutter/tests repo, include a link to the migration guide as per the breaking change policy.

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 Flutter Style Guide and the C++, Objective-C, Java style guides.
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt. See testing the engine for instructions on writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the CLA.
  • All existing and new tests are passing.

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

@flutter-dashboard flutter-dashboard bot added the platform-web Code specifically for the web engine label Nov 7, 2022
@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.

@a-wallen a-wallen marked this pull request as draft November 7, 2022 21:27
@flutter-dashboard
Copy link

This pull request has been changed to a draft. The currently pending flutter-gold status will not be able to resolve until a new commit is pushed or the change is marked ready for review again.

@a-wallen a-wallen force-pushed the remove_deprecated_updateSemantics branch from a34c6d5 to fe7fc58 Compare November 7, 2022 23:45
@a-wallen a-wallen force-pushed the remove_deprecated_updateSemantics branch from fe7fc58 to 2edb658 Compare November 8, 2022 01:28
@a-wallen a-wallen marked this pull request as ready for review November 8, 2022 18:08
@a-wallen a-wallen marked this pull request as draft November 8, 2022 18:08
///
/// In either case, this function disposes the given update, which means the
/// semantics update cannot be used further.
@Deprecated('''
Copy link
Contributor

Choose a reason for hiding this comment

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

Just checking: has this been deprecated for a year? It looks like the deprecation notice was just added a month ago.

https://docs.flutter.dev/resources/compatibility#deprecation-policy

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No this has not been deprecated for over a year. That's a good catch. Thanks, Greg!

Is the solution to let the PR sit until this year passes?

@gspencergoog
Copy link
Contributor

No, but I'm surprised that the deprecation notice doesn't include the version that the deprecation first appeared in. We have a lint for that on the Framework side. The deprecation notice should look like this.

Once it has the version number in it, then we'll be able to programmatically detect that it is a year old, and we'll remove it at that time (this is the kind of thing that @Piinks has been doing recently).

Kate, are we supposed to also have deprecation lint checks (for deprecation message format compliance) in the engine dart:ui code?

Copy link
Contributor

@Piinks Piinks left a comment

Choose a reason for hiding this comment

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

How long has this been deprecated for?
The analyzer-enforced deprecation format only applies in flutter/flutter right now I think. Same for the deprecation policy, we have not applied it to flutter/engine.

We have been discussing expanding to other packages like dart:ui , but since we haven't yet we probably shouldn't remove this right now. Especially if it has not been announced or had a migration guide generated yet.

@a-wallen
Copy link
Contributor Author

a-wallen commented Nov 9, 2022

@Piinks, it's been deprecated since #36675, about one month.

@gspencergoog
Copy link
Contributor

@Piinks I think we should probably extend the deprecation notice checks to the dart:ui package, since as far as our customers are concerned, it's part of Flutter's Dart code (they probably consider it to be covered by our deprecation policy). What do you think?

@Piinks
Copy link
Contributor

Piinks commented Nov 9, 2022

@Piinks I think we should probably extend the deprecation notice checks to the dart:ui package

Totally, that is something we have been discussing. It is just part of the custom analyzer script that runs on CI.

@Piinks
Copy link
Contributor

Piinks commented Nov 9, 2022

@Piinks, it's been deprecated since #36675, about one month.

So the warning has not even shipped to stable yet. We should probably wait so folks have time to migrate.

@a-wallen a-wallen closed this Nov 22, 2022
@a-wallen a-wallen reopened this Nov 22, 2022
@skia-gold
Copy link

Gold has detected about 2 new digest(s) on patchset 2.
View them at https://flutter-engine-gold.skia.org/cl/github/37396

@goderbauer goderbauer closed this Mar 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs tests platform-web Code specifically for the web engine
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move updateSemantics from PlatformDispatcher to FlutterView
5 participants