I have been trying to do flutter doctor but its unable to find the visual studio toolchain
This is what did
Install Flutter 2.2.0 version
Install visual studio proffesional 2019 with desktop c++ component ( did few uninstall and install just to ensure its not corrupted)
Replace the vswhere.exe with 3.1.1 and 3.0.3 version
List item
Change jdk to 1.8
Enable windows desktop via flutter config
I realized when i do flutter doctor -v the vshwere.exe just keep poping up and close 2 3 times it seems trying to locate something
Related
I am having problems with android studio upon updating to electric eel. This was not a problem before update. I have a Mac M1 and flutter version is Flutter 3.3.10 • channel stable
When Running flutter doctor -v I get this for the android studio section:
Android Studio (version 2022.1)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
✗ Unable to find bundled Java version.
• Try updating or re-installing Android Studio.
How do I resolve this issue?
For Windows Users
Step - 1
Install Java JRE (JAVA RUNTIME ENVIRONMENT)
Link
https://www.java.com/en/download/manual.jsp
After downloading Click on Install and Change Installation folder any folder you like
Step - 2
Copy all of this content and GO TO Android Studio Installation Path
for-example
C:\Program Files\Android\Android Studio\jre
By default Android Studio has a folder called JRE
go inside jre folder and paste everything
If JRE folder in Android Studio has anything inside please delete it before pasting.
Congratulations Windows User
I was struggling with this for like two days and I search it on YouTube and found nothing everything was one year old so I end up Julia Pak Channel while she had Mac but I got the idea to find a solution for windows (basically copy-pasting idea) and find a link in her description and I saw her content and she does an amazing job to help people
So Major Thanks to her.
If anyone ends up on her beautiful YouTube Channel
Give her a like and Subscribe to show some LOVE
YouTube:- https://www.youtube.com/#Juliapak
Thanks.
As you can see Unable to find bundled Java version. is the problem when running flutter doctor -v after updating.
This is the work around I did in terminal:
cd /Applications/Android\ Studio.app/Contents/jbr
ln -s ../jbr jdk
ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk
Then I did this in finder:
locate Android Studio
right click on Android Studio and click `show package contents'
create a new folder and call it jre
You'll see a jbr folder, open it and copy its contents
paste those contents into the jre folder you created. File structure looks like this now
Honestly I think this is creating redundancy of some sort, but hey it works!🎉🎉 when I run flutter doctor -v I now get this for android studio.
[✓] Android Studio (version 2022.1)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build
11.0.15+0-b2043.56-8887301)
I'm sure there are better work arounds but this works for me.🥳🥳🥳
link to video showing how I solved this
For mac users, just go to where is your android studio installed
if you install android studio using the installer use
cd /Applications/Android\ Studio.app/Contents
if using JetBrains toolbox use
cd "/Users/ahmedhnewa/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/221.6008.13.2211.9477386/Android Studio.app/Contents"
you can go to the settings of the ide and find where it's installed
then just type
open .
so it will be opened in finder
copy the folder jbr and rename it to jre
I think the flutter team should look into this so the flutter command line
can know where the bundled JDK is in the new android studio update.
currently, there is no any recent update to the flutter tool but after it get update the issue should be fixed without copy the jbr folder and rename the copied one to jre
Edit
For Linux it's almost the same, just the path of android studio is different, it's depend on where and how did you installed it, for Windows users
just right click on the android studio in the desktop and open file location and
do the exists same thing on all platforms
This solution worked for me on my Mac
Navigate to Applications on finder Right Click Android Studio. Select "Show package contents". And then right-click "Contents" and select "New Terminal at Folder". Finally copy and paste this line and press enter.
ln -s jbr jre
Thank you so much! After upgrading to Android Studio Electric Eel when I check flutter doctor I came across with "unable to find bundled java version" then I saw that and that helped a lot! Thanks for your effort.
Simple Guide
There is problem with Electric eel
Android Studio App contents after installation is not having jre dir
On Mac What i did:
copy the jbr directory available and name it as jre
jre directory with contents will resolve this
I created a sample flutter project and I want to see the result in chrome.
when I run main.dart on chrome I get a white blank page as result!
here is my flutter doctor:
Doctor summary (to see all details, run flutter doctor -v):
Flutter (Channel stable, 3.3.0, on Ubuntu 22.04.1 LTS 5.15.0-56-
generic,locale en_US.UTF-8)
Android toolchain - develop for Android devices
cmdline-tools component is missing
Run `path/to/sdkmanager --install "cmdline-tools;latest"`
See https://developer.android.com/studio/command-line for more
details.
Chrome - develop for the web
Linux toolchain - develop for Linux desktop
clang++ is required for Linux development.
It is likely available from your distribution (e.g.: apt
install clang), or can be downloaded from
https://releases.llvm.org/
CMake is required for Linux development.
It is likely available from your distribution (e.g.: apt
install cmake), or can be downloaded from
https://cmake.org/download/
ninja is required for Linux development.
It is likely available from your distribution (e.g.: apt
install ninja-build), or can be downloaded from
https://github.com/ninja-build/ninja/releases
pkg-config is required for Linux development.
It is likely available from your distribution (e.g.: apt
install pkg-config), or can be downloaded from
https://www.freedesktop.org/wiki/Software/pkg-config/
Android Studio
android-studio-dir =
/home/mbunderline76/.local/share/JetBrains/Toolbox/apps/IDEA-
U/ch-0
Unable to find bundled Java version.
IntelliJ IDEA Ultimate Edition (version 2022.3)
Connected device (2 available)
HTTP Host Availability
Doctor found issues in 3 categories.
any idea what is going on?
by the way i'm using Intellij Idea Ultimate
Fix these issues first.
Flutter command Line tools
Flutter Java Bundled Link
then again run flutter doctor to make sure these errors are gone.
then run flutter -v -d chrome run Or Pick " Chrome Web " in your Vscode or AndroidStudio.
Hope this works, Enjoy.
I already have dart sdk installed:
running dart --version gives me:
Dart SDK version: 2.17.6 (stable) (Tue Jul 12 12:54:37 2022 +0200) on "macos_arm64"
up until now I was using vscode but now I need to go back to android studio which gives me the following error on top of every dart file:
Dart sdk is not configured
N.B: This is not a fresh install. I have been using flutter and vscode in my mac for quite some time now
Try this in your Android Studio.
Preference
plugin
search for flutter from the market
install flutter and also make sure dart is install, you can confirm by searching for dart also.
restart you android studio after and you should be fine
I was developing a Flutter app using the stable channel, in Android Studio, now I upgraded Flutter Plugin to 53 and now when I try to run my app I receive this error
Could not find an option named "devtools-server-address".
Run 'flutter -h' (or 'flutter <command> -h') for available flutter commands and options.
Someone suggested using the dev channel, but I need to continue in the stable channel!
Suggestion Link:
Could not find an option named "devtools-server-address". when trying to run flutter app from AndroidStudio
Just found the fix:
$ flutter upgrade
$ flutter clean
Then select Invalidate Caches / Restart from the Android Studio File menu!
Follow the following steps:
Run the command flutter clean from terminal.
Go to File -> Invalidate Cache and Restart -> Invalidate and Restart.
Now try running your app. The issue should disappear.
If the error still persists: Go to File -> Settings -> Language & frameworks -> Flutter.
Check that the sdk path is appropriate as shown in below image:
Check the Dart sdk path too:
This should solve your problem.
Follow the steps:
File -> Invalidate Cache and Restart.
Run flutter clean
Worked For me.
For a little bit more details, you could also run flutter doctor to see what is happening.
In my case, I've recently updated Android Studio to version 4.2 and when I run the command it gives me:
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel unknown, 1.22.6, on macOS 11.2.2 20D80 darwin-x64, locale en-GI)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 12.4)
[!] Android Studio (version 4.2)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
[!] IntelliJ IDEA Ultimate Edition (version 2019.3.3)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
[!] IntelliJ IDEA Community Edition (version 2020.1.2)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
[✓] Connected device (1 available)
! Doctor found issues in 3 categories.
As well you could run flutter doctor -v as specified to get more details as verbose (where -v stands for verbose)
In my case the plugins where not visible for Android Studio and wasn't using a stable version of Flutter which didn't allow me to enable the plugins, although they were installed.
After this I've switched to a stable version of Flutter, double checked any required updated from Android Studio, uninstall and re-install the plugins and worked like a charm.
Want to mention that flutter clean and flutter pub get were necesarry afterwards.
Here is the flutter doctor result:
[√] 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.
I have already installed the flutter plugin. But the problem still exists. How can I fix this?
Just run this on your terminal (Mac users)
ln -s ~/Library/Application\ Support/Google/AndroidStudio4.1/plugins ~/Library/Application\ Support/AndroidStudio4.1
Well hello all
I would suggest you all to follow the steps what flutter documentation sites tells you to do
For windows-->There are some people who got detected flutter and dart plugins by the flutter doctor and few are not
I got this issue when I tried to install ...
I did everything like installed flutter and dart plugin still my flutter doctor haven't detected the plugins ...
following steps worked for me
flutter channel dev
flutter upgrade
flutter config --android-studio-dir="C:\Program Files\Android\Android Studio"
flutter doctor -v
note :--- flutter config --android-studio-dir="C:\Program Files\Android\Android Studio" should be example flutter config "C:\Program Files\Android\Android Studio"
above steps worked for me i hope it will helps you too :)
change channel master to dev.
then upgrade.
flutter channel dev
flutter channel upgrade
try again
flutter doctor
Note: I think it's Android Studio 4.1 issue...
Since you say you have flutter plugin installed in Android Studio, and if Android Studio correctly shows your installed plugin, there is no reason to believe any third-party tool reporting otherwise.
Also, this will not affect your flutter development and your IDE plugins will work as expected inside the IDE and flutter tool's commands work independent of the IDE in use.
Android Studio 4.1 apparently changed its default plugin install path.
Related github issue: [flutter_tools] IDE plugin validators should be deprecated #61246
Flutter does not directly use the IDE plugins, so doctor failing to detect them does not affect any behavior (it's just annoying).
open terminal:
run> flutter channel dev
run> flutter channel updrade
open terminal:
Mac User:
flutter config --android-studio-dir=/Applications/Android\ Studio.app
Reinstall Flutter Plugin from Android Studio
Are you using Android Studio V 4.1?
With Android Studio V4.1 there is a problem.
Try to reinstall Android Studio but Version 4.0.1 and try it again, chances are this will fix your problem.
Open Android studio
Follow the Path Configure > Plugins > marketplace > search Flutter & Dart > Install
Restart IDE(Android studio)
Open Terminal and Export Flutter Path
and run flutter doctor -v
If you are upgrading for an existing project:
Run
git clone https://github.com/flutter/flutter.git
in your terminal.
The be sure to delete the Flutter folder in your App's root directory. Otherwise you will get over 50k errors popping up
Check your flutter PATH
which flutter
if you get /path-to-flutter-sdk/bin//flutter or similar you may have added an extra / in your $HOME/.rc_file. Remove the last '/', restart terminal and try again
this worked for me
flutter channel dev
flutter doctor