-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[web] Update package:web to ">=0.5.1 <2.0.0" #7202
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
Conversation
(First push to see how CI likes this, expecting a bunch of errors!) |
|
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.
@ditman There is some cleanup to do that won't show up as build errors since a lot of the import statements are like this: import 'package:web/web.dart' as web; which will hide duplicate type errors
import 'package:web/web.dart' as web;
/// Adds a "disablePictureInPicture" setter to [web.HTMLVideoElement]s.
extension NonStandardSettersOnVideoElement on web.HTMLVideoElement {
// TODO(srujzs): This will be added in `package:web` 0.6.0. Remove this helper
// once it's available.
external set disablePictureInPicture(bool disabled);
}
/// Adds a "disableRemotePlayback" and "controlsList" setters to [web.HTMLMediaElement]s.
extension NonStandardSettersOnMediaElement on web.HTMLMediaElement {
// TODO(srujzs): This will be added in `package:web` 0.6.0. Remove this helper
// once it's available.
external set disableRemotePlayback(bool disabled);
external set controlsList(String? controlsList);
} |
For any packages without any code changes (which is currently all of them, but I'm not sure how preliminary that is), consider expanding the range to include 1.x instead of requiring 1.x. According to pub there are about 150 packages depending on Not a requirement by any means, but something to consider. |
Brackets the package:web dependency in gis_web to allow for `">=0.5.1 <2.0.0"`. ## Issues This is needed so we can rebase and land: * Part of: #7202
@Rexios80 you're right, I'll eventually get to those as we fix the more core dependencies. There's only a few "package_web_tweaks" in the different packages which should be "easy to remove".
@Rexios80 we have fairly strict warnings-as-errors in the build; I think those errors will eventually show up once the "all_packages" app is able to resolve to web:^1.0.0. Or do you mean those will fail at run-time or some time after publishing?
Good call @stuartmorgan, I'll try to expand the untouched packages to a range, as long as the code is compatible. |
I'm not sure they will show up as warnings/errors since technically nothing will be wrong. The extensions will just shadow the real types (if the web import is named) and fields (always). They should still build fine, there will just be superfluous code. |
@Rexios80 Ah yes, I think this is fine (for a while). IMO it's very nice that we can write this type of "bridge" code across major versions for a change! 😭 We can (and should) remove the As @stuartmorgan said, the packages that don't require actual code changes to go to |
In the past I would be opposed to maintaining a version range on a dependency since it's really easy to accidentally break backwards compatibility. However |
We've been doing that in our CI, as part of presubmit checks, for two years. The pana check was actually added because I recommended it based on our setup. |
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 "@test-exemption-reviewer" in the #hackers channel in Chat (don't just cc them here, they won't see it! Use 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. |
(This should trigger all tests?) |
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.
Just some small things I noticed. Otherwise LGTM!
packages/google_sign_in/google_sign_in_web/lib/src/flexible_size_html_element_view.dart
Outdated
Show resolved
Hide resolved
@@ -2,7 +2,7 @@ name: web_benchmarks | |||
description: A benchmark harness for performance-testing Flutter apps in Chrome. | |||
repository: https://github.com/flutter/packages/tree/main/packages/web_benchmarks | |||
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+web_benchmarks%22 | |||
version: 2.0.0 | |||
version: 2.0.1 |
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.
Since there is a code change in this package, should this be 2.1.0
?
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.
Nah, the code changes are so minimal that I think a patch version should be enough.
@ditman Should we ask for a test exemption on Discord? |
@Rexios80 it's almost 8PM PT, so it's probably a little bit late (or too early) for Discord. @stuartmorgan has test exemption powers and can also answer your question about the |
packages/google_maps_flutter/google_maps_flutter_web/CHANGELOG.md
Outdated
Show resolved
Hide resolved
packages/google_sign_in/google_sign_in_web/example/pubspec.yaml
Outdated
Show resolved
Hide resolved
packages/google_sign_in/google_sign_in_web/lib/src/flexible_size_html_element_view.dart
Outdated
Show resolved
Hide resolved
test-exempt: code refactor with no semantic change |
|
@kevmoo There are some small tweaks left |
OK, I've addressed all of the comments. It seems that if CI is happy, we're all happy, so adding |
This is now published, thanks!
|
flutter/packages@27896d1...cc9ff47 2024-08-02 [email protected] [tool] Add note about clang version used in CI to tool readme (flutter/packages#7273) 2024-08-02 [email protected] [ci] Re-enable google_maps_flutter_web integration tests. (flutter/packages#7269) 2024-08-01 [email protected] [web] Update package:web to ">=0.5.1 <2.0.0" (flutter/packages#7202) 2024-08-01 [email protected] [go_router] Documentation for StatefulShellRoute (flutter/packages#6308) 2024-08-01 [email protected] [google_maps_flutter] Switch Android examples to TLHC (flutter/packages#7282) 2024-08-01 [email protected] Manual roll Flutter from f817e51 to e2e4398 (5 revisions) (flutter/packages#7276) 2024-08-01 [email protected] [various] Clean up C++ formatting (flutter/packages#7272) 2024-08-01 [email protected] [shared_preferences] fix stringlist bug (flutter/packages#7268) 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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
flutter/packages@27896d1...cc9ff47 2024-08-02 [email protected] [tool] Add note about clang version used in CI to tool readme (flutter/packages#7273) 2024-08-02 [email protected] [ci] Re-enable google_maps_flutter_web integration tests. (flutter/packages#7269) 2024-08-01 [email protected] [web] Update package:web to ">=0.5.1 <2.0.0" (flutter/packages#7202) 2024-08-01 [email protected] [go_router] Documentation for StatefulShellRoute (flutter/packages#6308) 2024-08-01 [email protected] [google_maps_flutter] Switch Android examples to TLHC (flutter/packages#7282) 2024-08-01 [email protected] Manual roll Flutter from f817e51 to e2e4398 (5 revisions) (flutter/packages#7276) 2024-08-01 [email protected] [various] Clean up C++ formatting (flutter/packages#7272) 2024-08-01 [email protected] [shared_preferences] fix stringlist bug (flutter/packages#7268) 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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
flutter/packages@27896d1...cc9ff47 2024-08-02 [email protected] [tool] Add note about clang version used in CI to tool readme (flutter/packages#7273) 2024-08-02 [email protected] [ci] Re-enable google_maps_flutter_web integration tests. (flutter/packages#7269) 2024-08-01 [email protected] [web] Update package:web to ">=0.5.1 <2.0.0" (flutter/packages#7202) 2024-08-01 [email protected] [go_router] Documentation for StatefulShellRoute (flutter/packages#6308) 2024-08-01 [email protected] [google_maps_flutter] Switch Android examples to TLHC (flutter/packages#7282) 2024-08-01 [email protected] Manual roll Flutter from f817e51 to e2e4398 (5 revisions) (flutter/packages#7276) 2024-08-01 [email protected] [various] Clean up C++ formatting (flutter/packages#7272) 2024-08-01 [email protected] [shared_preferences] fix stringlist bug (flutter/packages#7268) 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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
This PR updates packages that depend on
package:web
toweb: ">=0.5.1 <2.0.0"
.Issues
package:web
version1.0.0
flutter#151981Pre-launch Checklist
dart format
.)[shared_preferences]
pubspec.yaml
with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.CHANGELOG.md
to add a description of the change, following repository CHANGELOG style, or this PR is exempt from CHANGELOG changes.///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.