Flutter

BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 61 + flutter

BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 61

Solution:

I just update distributionUrl value at android\gradle\wrapper\gradle-wrapper.properties to a gradle compatible with my JDK version (19)

distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-all.zip

Error: module java.base does not "opens java.io" to unnamed module @65c2d059 + Flutter

The solution from GitHub has worked for me. It was no need to downgrade Java JDK. Just changed gradle version in gradle-wrapper properties to 7.1.1 (6.x does not support java 16), and adding the following line in gradle.properties:

Debian 11 Bullseye environment

Debian 11 Bullseye

1. After installing the OS, Update the /etc/apt/sources.list

deb http://deb.debian.org/debian bullseye main
deb-src http://deb.debian.org/debian bullseye main

deb http://deb.debian.org/debian-security/ bullseye-security main
deb-src http://deb.debian.org/debian-security/ bullseye-security main

deb http://deb.debian.org/debian bullseye-updates main
deb-src http://deb.debian.org/debian bullseye-updates main

deb http://ftp.hk.debian.org/debian sid main non-free-firmware

2.

Sudo apt update

to update the sources
3.

Telephony sendsms not working + Unhandled Exception: PlatformException(failed_to_fetch_sms, Flutter Telephony: Error getting SmsManager, null, null) | Flutter

Fix using

installed telephony version 0.1.1
flutter version 2.10.3

You uploaded an APK or Android App Bundle which has an activity, activity alias, service or broadcast receiver with intent filter, but without 'android:exported' property set | flutter

Uploading flutter android sdk 31 version makes an error on google play store.

You uploaded an APK or Android App Bundle which has an activity, activity alias, service or broadcast receiver with intent filter, but without 'android:exported' property set. This file can't be installed on Android 12 or higher. See: developer.android.com/about/versions/12/behavior-changes-12#exported

android app bundle error

error might indicate a memory leak if setState() is being called because another object is retaining a reference to this State object after it has been removed from the tree | flutter

memory leak error/warning

This error might indicate a memory leak if setState() is being called because another object is retaining a reference to this State object after it has been removed from the tree. To avoid memory leaks, consider breaking the reference to this object during dispose().

Just add this line of code before calling the setstate.

if (!mounted) {
  return;
}
// your setState here

CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate using an letsencrypt-signed webserver | flutter

I have spent so many hours just to figure this out. I use wss(secure) for my django websocket. Ive realized that using firebase and firecamp is working perfectly, but in my flutter app websocket connect it does not work. arggg, spending many hours working this error (I initially dont know why the heck is this).

Adding this piece of code in the main.dart file fix my issue. :)