Flutter doctor: Flutter and dart plugins not installed - android-studio

This is problem, I have already installed flutter and dart plugin but its showing I haven't , I freshly installed both android studio and flutter as I just started it
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable`enter code here`, on Microsoft Windows)
[√] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[!] Android Studio (version 4.1.0)
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
[√] VS Code (version 1.52.1)
[√] Connected device (1 available)
! Doctor found issues in 1 category.

This is a known and recurring issue with Flutter cli and the 'moving target' that is AS4.1 and other IDE file locations. See: https://github.com/flutter/flutter/issues/61246
(and the links it contains).
It can be safely ignored if your plugins in AS4.1 are working fine.

You just need to add the Flutter and Dart plug-ins to your Android Studio. Simply open the Android Studio program, select File > Settings > Plugins (or Android Studio > Preferences > Plugins on a Mac). Type in The word flutter to bring up the flutter.dev plug-in and click to install it. Installing Flutter will automatically install Dart. Rerun flutter doctor again, and assuming your $PATH is configured correctly, it will show that the plug-ins are detected.

I'm having the same problem for the last two months. It happened after the new Flutter update. I tried every solution: whether changing Channel to dev to updating SDKs. I have been ignoring it and everything works perfectly .

Check if Android Studio is added to your Path in environment variables

Check whether your flutter sample project is running or not ,if it is running finely then it will not create problem. I am saying this because i happend with me also but it didn't affected any projects i have created.

Related

Android Studio 4.1.2 - Dart And Flutter is not installed in "flutter doctor"

I've recently installed android studio 4.1.2 with flutter 1.22.6
even though I installed flutter and dart plugins in android studio the result of 'flutter doctor' command was as follows.
[√] Flutter (Channel stable, 1.22.1, on Microsoft Windows [Version
10.0.18362.30], locale en-US)
[√] Android toolchain - develop for Android devices (Android SDK version
30.0.2)
[!] Android Studio
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
[!] Connected device
! No devices available
! Doctor found issues in 2 categories.
Now for clear error act as below (Steps worked for me):
flutter channel dev
flutter upgrade
flutter config --android-studio-dir="C:\Program Files\Android\Android Studio"
flutter doctor -v
It is a problem in Flutter config detection. If you start Android Studio and plugins installed, you can use it and all functionality will works fine. You can find solutions in issue on GitHub.
It's a bug in the Flutter SDK.
You can ignore it. Everything works as intended.
The reason for getting that error is because of the Android version you are using. If you should run:
flutter doctor -v,
You should get the Android version flutter is trying to check the configuration for.
In my case, it shows Android Studio version 4.1.0 even though i have Android Studio 4.1.2 installed with the required plugins. So, as long as it keeps expecting that Android studio version but with a different version installed, you should be getting same error. So, i think the solution to that is to get the Android version flutter doctor displays or probably wait for the next stable release of flutter that supports Android version 4.1.2.

How to solve "target died before we could attach" message in Flutter console?

i am new to android app development, i just started learning flutter and there is so much information to take in , i downloaded a project from github to try and make sense out the things that i only read about online and when i run the app this is what i get :
Screenshot1
Screenshot2
in the red boxes you can see there is a lot of things saying " target died before we could attach " what exactly is this ? is it something to be concerned about ? i tried googling it to see if i find some information about em but i couldn't find anything useful , maybe i was searching it the wrong way ...
Update: After running the "flutter doctor" this is what i got :
C:\src\flutter\flutter>flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 1.22.4, on Microsoft Windows [Version 10.0.19042.631], locale en-US)
[!] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
X Android license status unknown.
Run flutter doctor --android-licenses to accept the SDK licenses.
See https://flutter.dev/docs/get-started/install/windows#android-setup for more details.
[!] Android Studio (version 4.1.0)
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
[!] VS Code (version 1.52.0)
X Flutter extension not installed; install from
https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter
[√] Connected device (1 available)
! Doctor found issues in 3 categories.
but i am sure that i have installed the flutter and dart plugin
I have no idea what causes this error but this is how I resolved mine.
Confirm that flutter doctor generates no errors.
Uninstall any versions of the application from your emulator.
flutter run
Now you should be okay.
From a console window that has the Flutter directory in the path, run the following command to see if there are any platform dependencies you need to complete the setup:
C:\src\flutter>flutter doctor
This command checks your environment and displays a report of the status of your Flutter installation. Check the output carefully for other software you might need to install or further tasks to perform
source here
# Edit
If the doctor command does not indicate an error, then try to create a new project and copy and paste the classes from the project you downloaded to your new project. Flutter need to download the Gradle, it may be some IDE bug that can be solved by creating a new project

Flutter not installing properly for Android Studio

So I am tryin to download flutter on android studio. I downloaded the plugin for it and it shows up on android studio when I look for it but when I run
flutter doctor
it says
[!] Android Studio (version 4.1.0)
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
I don't know what the problem is because I have the plugin installed on android studio but flutter can't find it. How can I fix this issue?
It's a known bug that u can ignore and it doesn't affect you as long as u have the plugins installed. For more info check This issue
The error will disappear just after running it once. Try running it.
Try this,
check your Dart SDK path correctly, after this apply.
may this helpful for you.

Flutter plugin not installed when using Android-Studio

Hi I am getting the following error.
$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 1.20.2, on Microsoft Windows [Version 10.0.18362.1016], locale en-IN)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
[!] Android Studio
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
[√] VS Code (version 1.48.2)
[√] Connected device (1 available)
! Doctor found issues in 1 category.
I have installed both plugins and everything in environment variable.
I installed Android studio in my custom path, this may be the issue. I have given the current android-studio path using flutter config command.
When I check the Installation path the plugin is not there(flutter and dart). It is installed in C:\Users\AppData\Roaming\Google\AndroidStudio4.1\ path.
So I set that path then shows another error that is, embedded java is not found.
Also I tried copying it to custom path. But no luck.
Thanks for your help
If you are doing everything on vs code having flutter and dart not installed on android studio should not be an issue. You only need android studio to connect to the emulator. I can run my flutter code with both plugins not installed.

I want to run flutter on windows 7 with my android phone as a emulator . truned on my debugging mode. How can i fix issue of flutter doctor command

$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, v1.5.4-hotfix.2, on Microsoft Windows [Version 6.1.7601], locale en-US)
[!] Android toolchain - develop for Android devices (Android SDK version 29.0.0)
X Android license status unknown.
Try re-installing or updating your Android SDK Manager.
See https://developer.android.com/studio/#downloads or visit https://flutter.dev/setup/#android-setup for detailed instructions.
[!] Android Studio (version 3.4)
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
[√] VS Code (version 1.35.1)
!] Connected device
! No devices available
! Doctor found issues in 3 categories.
You have to accept licences agreement from the android SDK
You can type this command sdkmanager --licenses or navigate to your SDK folder and type tools/bin/sdkmanager --licenses.
This will ask you if you want to review non-accepeted licenses. You just have to type y to accept or n if you want to decline.
PS: Don't forget to connect your device and test debug mode with adb devices
Open VS Code, then download Dart and flutter plugin. Don't forget to implement the fix given by #user8773560

Resources