Skip to content

Windows Flutter apps crash silently on some machines after 3.27.4 #169178

@eduardohr-muniz

Description

@eduardohr-muniz

Steps to reproduce

Create a new Flutter app:

1-
flutter create test_app
Build the Windows executable:

2-
cd test_app

3-
flutter build windows

Run the generated executable on multiple Windows machines:

Machines with Flutter version 3.27.4 and below → app works normally.

Machines with Flutter 3.29.0 and above → app may crash immediately on some computers without showing a window or error.

Expected results

The app should open and display the counter UI on all machines, as it does on version 3.27.4 and below.

Actual results

On Flutter 3.29.4:

On some Windows machines, the app crashes silently on launch (nothing appears).

No error logs are shown.

This happens even with the default counter app generated by flutter create.

Code sample

Code sample
import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple)),
      home: const MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key, required this.title});

  final String title;

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  int _counter = 0;

  void _incrementCounter() {
    setState(() {
      _counter++;
    });
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(backgroundColor: Theme.of(context).colorScheme.inversePrimary, title: Text(widget.title)),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: <Widget>[
            const Text('You have pushed the button this many times:'),
            Text('$_counter', style: Theme.of(context).textTheme.headlineMedium),
          ],
        ),
      ),
      floatingActionButton: FloatingActionButton(onPressed: _incrementCounter, tooltip: 'Increment', child: const Icon(Icons.add)),
    );
  }
}

Screenshots or Video

Video demonstration

[Click for watch]

Logs

Logs I used Process Monitor (Procmon) to capture detailed logs on Windows during app launch. The logs show the differences in behavior between Flutter 3.27.4 (working) and 3.29.0+ (failing on some machines). I've attached the .PML files to help with further analysis.

Flutter 3.27.4 (working):

3_27_4.zip

Flutter 3.29.3 (crashing on some machines):

3_29_3.zip

Flutter Doctor output

Doctor output
flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.29.3, on Microsoft Windows [versÆo 10.0.26100.4061], locale pt-BR)
[✓] Windows Version (Windows 11 or higher, 24H2, 2009)
[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.1)
[✓] Chrome - develop for the web
[✓] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.13.5)
[✓] Android Studio (version 2024.3)
[✓] VS Code (version 1.100.2)
[✓] Connected device (3 available)
[✓] Network resources

• No issues found!

[3_27_4.zip](https://github.com/user-attachments/files/20358327/3_27_4.zip)
[3_29_3.zip](https://github.com/user-attachments/files/20358328/3_29_3.zip)

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: crashStack traces logged to the consolec: fatal crashCrashes that terminate the processe: device-specificOnly manifests on certain devicesplatform-windowsBuilding on or for Windows specificallyr: fixedIssue is closed as already fixed in a newer versionteam-windowsOwned by the Windows platform team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions