Skip to content

[shared_preferences] Variable binding in a condition requires an initializer fix #4407

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 7, 2023

Conversation

tarrinneal
Copy link
Contributor

Not sure that testing for this makes sense, unless we want to add old xcode versions to our test suite.

Let me know if I'm thinking about this incorrectly though.

fixes flutter/flutter#129983

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 tarrinneal requested a review from stuartmorgan-g July 7, 2023 19:51
@tarrinneal tarrinneal requested a review from cyanglaz as a code owner July 7, 2023 19:51
@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.

@tarrinneal
Copy link
Contributor Author

@Hixie This pr is in need of a test exemption as testing for this bug can only be done by creating a whole new shard that runs all of our tests on an older version of Xcode. I don't feel like this is worth the cost to automate testing for a rare issue such as this.

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

I agree this isn't worth the ongoing cost of maintaining an old-Xcode test shard. (Not just CI cost, but keeping it running in general.) I can't think of another instance we've had of this kind of issue offhand.

@Hixie
Copy link
Contributor

Hixie commented Jul 7, 2023

test-exempt: old xcode versions are support level 2 or 3.

@tarrinneal tarrinneal added autosubmit Merge PR when tree becomes green via auto submit App and removed needs tests labels Jul 7, 2023
@auto-submit auto-submit bot merged commit 38f4b59 into flutter:main Jul 7, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 10, 2023
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Jul 10, 2023
flutter/packages@b61eea1...4469c5e

2023-07-08 [email protected] Roll Flutter from d55a7d8 to 65ff3cb (21 revisions) (flutter/packages#4413)
2023-07-08 [email protected] [tool] Update Dart SDK version (flutter/packages#4402)
2023-07-08 [email protected] [url_lancher] Don't use `canLaunchUrl` in Link (flutter/packages#4400)
2023-07-08 [email protected] Remove unused autosubmit configuration file (flutter/packages#4410)
2023-07-07 49699333+dependabot[bot]@users.noreply.github.com [file_selector]: Bump androidx.annotation:annotation from 1.5.0 to 1.6.0 in /packages/file_selector/file_selector_android/android (flutter/packages#4312)
2023-07-07 [email protected] Roll Flutter from bc49cd1 to d55a7d8 (17 revisions) (flutter/packages#4403)
2023-07-07 [email protected] [shared_preferences] Variable binding in a condition requires an initializer fix (flutter/packages#4407)
2023-07-07 [email protected] [go_router] implemented helpers for StatefulShellRoute (flutter/packages#4228)
2023-07-07 [email protected] [in_app_purchase_android] Bump com.android.billingclient:billing from 5.2.0 to 6.0.0. (flutter/packages#4390)
2023-07-07 [email protected] [tool] Use 'flutter pub get' for Flutter packages (flutter/packages#4397)
2023-07-07 [email protected] [ci] Enable LUCI stable custom Linux tests (flutter/packages#4404)
2023-07-07 [email protected] [tool] Fix --current-package for app-facing packages (flutter/packages#4399)
2023-07-07 [email protected] [ci] Switch some tests to LUCI (flutter/packages#4395)
2023-07-07 [email protected] [flutter_markdown] Pass parent TextStyle down to MarkdownElementBuilder.visitElementAfter (flutter/packages#4393)
2023-07-07 49699333+dependabot[bot]@users.noreply.github.com Bump github/codeql-action from 2.3.3 to 2.20.3 (flutter/packages#4394)

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
gbtb16 pushed a commit to gbtb16/flutter that referenced this pull request Nov 6, 2023
flutter/packages@b61eea1...4469c5e

2023-07-08 [email protected] Roll Flutter from d55a7d8 to 65ff3cb (21 revisions) (flutter/packages#4413)
2023-07-08 [email protected] [tool] Update Dart SDK version (flutter/packages#4402)
2023-07-08 [email protected] [url_lancher] Don't use `canLaunchUrl` in Link (flutter/packages#4400)
2023-07-08 [email protected] Remove unused autosubmit configuration file (flutter/packages#4410)
2023-07-07 49699333+dependabot[bot]@users.noreply.github.com [file_selector]: Bump androidx.annotation:annotation from 1.5.0 to 1.6.0 in /packages/file_selector/file_selector_android/android (flutter/packages#4312)
2023-07-07 [email protected] Roll Flutter from bc49cd1 to d55a7d8 (17 revisions) (flutter/packages#4403)
2023-07-07 [email protected] [shared_preferences] Variable binding in a condition requires an initializer fix (flutter/packages#4407)
2023-07-07 [email protected] [go_router] implemented helpers for StatefulShellRoute (flutter/packages#4228)
2023-07-07 [email protected] [in_app_purchase_android] Bump com.android.billingclient:billing from 5.2.0 to 6.0.0. (flutter/packages#4390)
2023-07-07 [email protected] [tool] Use 'flutter pub get' for Flutter packages (flutter/packages#4397)
2023-07-07 [email protected] [ci] Enable LUCI stable custom Linux tests (flutter/packages#4404)
2023-07-07 [email protected] [tool] Fix --current-package for app-facing packages (flutter/packages#4399)
2023-07-07 [email protected] [ci] Switch some tests to LUCI (flutter/packages#4395)
2023-07-07 [email protected] [flutter_markdown] Pass parent TextStyle down to MarkdownElementBuilder.visitElementAfter (flutter/packages#4393)
2023-07-07 49699333+dependabot[bot]@users.noreply.github.com Bump github/codeql-action from 2.3.3 to 2.20.3 (flutter/packages#4394)

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
Labels
autosubmit Merge PR when tree becomes green via auto submit App p: shared_preferences
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[shared_preferences] Variable binding in a condition requires an initializer
3 participants