Skip to content

App crashes when on tapping on TextFormField in a release APK on Android 11 #66232

@trezm

Description

@trezm
  1. Run flutter create bug.
  2. Update the files as follows: main.dart
import 'package:flutter/material.dart';

void main() {
  runApp(
    MaterialApp(
        title: 'Flutter Demo',
        theme: ThemeData(
          primarySwatch: Colors.blue,
          visualDensity: VisualDensity.adaptivePlatformDensity,
        ),
        home: Scaffold(
            body: TextFormField(
          initialValue: "Hello",
        ))),
  );
}

  1. Run flutter build apk.
  2. Install the apk on a device running Android 11.
  3. Tap into the text field.

Expected results:
No crash

Actual results:
Crash

Logs Gotten from crashlytics, the error is:
Fatal Exception: java.lang.AbstractMethodError
abstract method "android.view.WindowInsets android.view.WindowInsetsAnimation$Callback.onProgress(android.view.WindowInsets, java.util.List)"
android.view.View.dispatchWindowInsetsAnimationProgress (View.java:11384)
android.view.ViewGroup.dispatchWindowInsetsAnimationProgress (ViewGroup.java:7433)
android.view.ViewGroup.dispatchWindowInsetsAnimationProgress (ViewGroup.java:7439)
...
Analyzing gifapp...                                                     

   info • Unused import: 'package:gifapp/main.dart' • test/widget_test.dart:11:8 • unused_import
  error • The function 'MyApp' isn't defined • test/widget_test.dart:16:29 • undefined_function

2 issues found. (ran in 2.9s)
[✓] Flutter (Channel beta, 1.22.0-12.1.pre, on Mac OS X 10.15.5 19F101, locale en-US)
    • Flutter version 1.22.0-12.1.pre at /Users/pete/dev/flutter
    • Framework revision 8b3760638a (5 days ago), 2020-09-15 17:47:13 -0700
    • Engine revision 4654fc6cf6
    • Dart version 2.10.0 (build 2.10.0-110.3.beta)

 
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
    • Android SDK at /Users/pete/Library/Android/sdk
    • Platform android-29, build-tools 29.0.3
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.0, Build version 12A7209
    • CocoaPods version 1.9.1

[✓] Android Studio (version 4.0)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 44.0.2
    • Dart plugin version 192.7761
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.49.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.14.1

[✓] Connected device (1 available)
    • Pixel 4 (mobile) • XXX • android-arm64 • Android 11 (API 30)

• No issues found!

Metadata

Metadata

Assignees

No one assigned

    Labels

    a: releaseChallenges faced when attempting to productionize an appa: text inputEntering text in a text field or keyboard related problemsc: fatal crashCrashes that terminate the processc: regressionIt was better in the past than it is nowe: OS-version specificAffects only some versions of the relevant operating systemfound in release: 1.22Found to occur in 1.22frameworkflutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onplatform-androidAndroid applications specificallywaiting for PR to land (fixed)A fix is in flight

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions