Skip to content

integration_test deprecation warning: 'windows' is deprecated: first deprecated in iOS 15.0 - Use UIWindowScene.windows on a relevant window scene instead #154365

Open

Description

@jmagman

When targeting iOS 15 or later, integration_test has an analysis warning:

integration_test/IntegrationTestPlugin.m:76:55 'windows' is deprecated: first deprecated in iOS 15.0 - Use UIWindowScene.windows on a relevant window scene instead

UIWindow *window = [UIApplication.sharedApplication.windows
filteredArrayUsingPredicate:[NSPredicate predicateWithFormat:@"keyWindow = YES"]].firstObject;

To reproduce, open the example app iOS project and set the iOS minimum target to iOS 15.

Activity

  1. added
    f: integration_testThe flutter/packages/integration_test plugin
    P3Issues that are less important to the Flutter project
    team-iosOwned by iOS platform team
    triaged-iosTriaged by iOS platform team
    on Aug 29, 2024
  2. jmagman commented on Sep 11, 2024

    @jmagman
    MemberAuthor

    Note, when this is fixed flutter/packages#7542 can be revived, increasing the deprecation warning check version in the packages repo.

  3. stuartmorgan-g commented on Jul 23, 2025

    @stuartmorgan-g
    Contributor

    The quick solution here would be to push a pragma warning around this, with a comment referencing the issue for actually replacing the code. We do that frequently in the packages repo (example).

  4. jmagman commented on Aug 5, 2025

    @jmagman
    MemberAuthor

    #173251 landed. However xcode analyze will continue to fail against the Flutter stable branch. Request a beta cherry-pick: #173304

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projectf: integration_testThe flutter/packages/integration_test pluginteam-iosOwned by iOS platform teamtriaged-iosTriaged by iOS platform team

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions