Skip to content

Conversation

@jmagman
Copy link
Member

@jmagman jmagman commented Dec 19, 2025

Seen in https://logs.chromium.org/logs/flutter/buildbucket/cr-buildbucket/8695102947197916049/+/u/Run_package_tests/native_test/stdout

I opened in Xcode 26.2 and let it "Fix".

FIAPPaymentQueueDeleteTests.swift:87:7: warning: 'TARGET_OS_*' preprocessor macros are not available in Swift; use 'os(iOS)' instead
  #if TARGET_OS_IOS
      ^~~~~~~~~~~~~
InAppPurchaseStoreKit2PluginTests.swift:396:25: warning: immutable value 'purchase' was never used; consider replacing with '_' or removing it
      case .success(let purchase):
                    ~~~~^~~~~~~~
                    _
TranslatorTests.swift:18:9: warning: variable 'map' was never mutated; consider changing to 'let' constant
    var map: [String: Any] = [
    ~~~ ^
    let

Pre-Review Checklist

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

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. 2 3

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request correctly addresses three analyzer warnings from Xcode 26.2 by updating a preprocessor macro, removing an unused variable, and changing a mutable variable to a constant. The CHANGELOG.md has also been updated. One minor style issue regarding indentation has been pointed out for improvement.

plugin.purchase(id: "consumable", options: nil) { result in
switch result {
case .success(let purchase):
case .success(_):
Copy link
Contributor

Choose a reason for hiding this comment

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

The tests are failing - Im guessing you might need to keep the "let purchase" because of IAP sandbox shennanigans. I think if you dont handle the VerificationResult it freaks out. Maybe we can do this instead

case .success(let purchase):
    _ = purchase 

Copy link
Member Author

Choose a reason for hiding this comment

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

Weird, this test passes on Xcode 26.2 locally.

Copy link
Member Author

Choose a reason for hiding this comment

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

And also passed on 16.4 locally...

Copy link
Contributor

Choose a reason for hiding this comment

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

oh thats scary

Copy link
Member Author

Choose a reason for hiding this comment

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

And it passed in CI when run a second time.

Copy link
Contributor

Choose a reason for hiding this comment

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

ugh the tests are flaky :( thats not good

Copy link
Contributor

Choose a reason for hiding this comment

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

@jmagman jmagman force-pushed the in-app-purchase-analyzer branch from c8f9c1b to 150a2aa Compare December 19, 2025 18:29
@jmagman jmagman marked this pull request as ready for review December 19, 2025 19:03
@jmagman jmagman added the autosubmit Merge PR when tree becomes green via auto submit App label Dec 19, 2025
@auto-submit auto-submit bot merged commit fb4f0c6 into flutter:main Dec 19, 2025
80 checks passed
@jmagman jmagman deleted the in-app-purchase-analyzer branch December 19, 2025 20:27
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: in_app_purchase platform-ios platform-macos

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants