-
Notifications
You must be signed in to change notification settings - Fork 295
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: Emulator didn't connect within 60 seconds #2773
Comments
same here, but for iOS - don't really care for Android. My error in VSCode Debug Console looks like:
[✗] Android toolchain - develop for Android devices [✓] Xcode - develop for iOS and macOS (Xcode 11.7) [!] Android Studio (not installed) [✓] Connected device (1 available) My emulator works - doesn't matter what device I use (saying this b/c someone mentioned using iPhone SE is relevant b/c it's not new enough?). I've made sure to:
|
@MaisGurbanov when you launch the emulator from VS Code and get this message, do you see the emulator launch and appear? If so, does it show up in @rasreee this seems like a different problem with a different message, could you file a separate issue and also include a log captured with the above command? Thanks! |
This issue has been marked stale because it is tagged awaiting-info for 30 days with no activity. Remove the stale label or comment to prevent the issue being closed in 10 days. |
You can try to wipe the data of the particular device. Go to -> Android Studio -> Tools -> AVD Manager -> [Select the down triangle on your chosen device] -> Wipe data. Now retry. |
This one works well for me |
It worked for me too, thank you. |
This does works but it keeps happening often. Any permanent fix on this? |
This comment was marked as spam.
This comment was marked as spam.
I'm working on a MacBook Air with M1 processor. If I run the iPhone Simulator, I can successfully use it in VSCode for debugging a Flutter app. But I cannot get VSCode to connect to the Android Emulator. The Emulator launches when I choose to Start Pixel 3 API S. But I then get the error "Error: Emulator didn't connect within 60 seconds". Any thoughts on how to get VSCode to connect to the Android Emulator from a Mac with M1 processor? |
@lukertaylor does the Android emulator show up when you run |
And if I start the iOS Simulator, I get: `luke@Lukes-MacBook-Air ~ % flutter devices iPhone 12 Pro Max (mobile) • 92D4EACC-982F-45CE-8AA2-33312D303A32 • ios • Device emulator-5554 is offline.` |
That looks like the problem. VS Code gets the device information from Flutter, so if Flutter believes the device is offline it won't provide it to us. There are a few reports of this in the Flutter issue tracker you might want to read through to see if any of their solutions work (for example this one). Hope that helps! |
Thanks Danny. I've got it sorted now. There were two things I needed to do:
|
Great, glad you sorted it! |
I am having the same issue above which I still cannot get rid of in vscode. Below is my flutter doctor output [!] Android toolchain - develop for Android devices (Android SDK version 29.0.3) [✓] Xcode - develop for iOS and macOS [✓] Chrome - develop for the web [✓] Android Studio (version 4.1) [✓] VS Code (version 1.57.1) [✓] Connected device (2 available) ! Doctor found issues in 1 category. |
@harguilar have you tried any of the suggestions above, or confirmed that the device shows up in |
Hi @DanTup, apple_ios_simulator • iOS Simulator • Apple • ios I see all the above ones. But When I tried to run then I get the error as the title of this tread. |
If the device isn't showing in I would probably try deleting the emulator and recreating it through Android Studio, and see if that makes any difference (launch it from Android Studio and then see if that shows up in |
Thank you so much man! I've been stuck at this for 3 days. |
Hey @alimirmohammad, really glad you got it sorted. Thanks go to @DanTup who helped me out. Good luck with your Flutter development! |
Have the same Issue, follow the steps you provided and everything works fine!! thanks for sharing the solution |
@lukertaylor's workaround did the trick, but... does anybody at flutter team know that? |
It launches the emulator but displays the Failed to launch Pixel 2 XL API 25: Error: Emulator didn't connect within 60 seconds |
@AlemsegedT after it's started, does it show up if you run |
Hey Danny @DanTup thanks for the response it didn't show up but I wipe the data of
emulator and cold booted it and I also updated the flutter version it now
works thank you again
|
@VicCislari fix worked for me! |
When I am trying to launch an Android emulator through the VS Code, I am receiving the following error:
"Failed to launch flutter emulator: Error: Emulator didn't connect within 60 seconds".
Below is the output for "flutter doctor -v" command outside of the VS Code:
[✓] Flutter (Channel stable, 1.20.3, on Mac OS X 10.15.6 19G2021, locale en-US)
• Flutter version 1.20.3 at /Users/mais.gurbanov/Flutter
• Framework revision 216dee60c0 (5 days ago), 2020-09-01 12:24:47 -0700
• Engine revision d1bc06f032
• Dart version 2.9.2
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /Users/mais.gurbanov/Android/sdk
• Platform android-28, build-tools 28.0.3
• ANDROID_HOME = /Users/mais.gurbanov/Android/sdk
• Java binary at:
/Library/Java/JavaVirtualMachines/jdk1.8.0_261.jdk/Contents/Home/bin/java
• Java version Java(TM) SE Runtime Environment (build 1.8.0_261-b12)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.7)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.7, Build version 11E801a
• CocoaPods version 1.9.3
[!] Android Studio (not installed)
• Android Studio not found; download from
https://developer.android.com/studio/index.html
(or visit https://flutter.dev/docs/get-started/install/macos#android-setup
for detailed instructions).
[✓] VS Code (version 1.48.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.14.0
[!] Connected device
! No devices available
"Flutter: Run Flutter Doctor" command's output inside of the VS Code:
[✓] Flutter (Channel stable, 1.20.3, on Mac OS X 10.15.6 19G2021, locale en-US)
• Flutter version 1.20.3 at /Users/mais.gurbanov/Flutter
• Framework revision 216dee60c0 (5 days ago), 2020-09-01 12:24:47 -0700
• Engine revision d1bc06f032
• Dart version 2.9.2
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /Users/mais.gurbanov/Android/sdk
• Platform android-28, build-tools 28.0.3
• Java binary at: /Library/Java/JavaVirtualMachines/jdk1.8.0_261.jdk/Contents/Home/bin/java
• Java version Java(TM) SE Runtime Environment (build 1.8.0_261-b12)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.7)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.7, Build version 11E801a
• CocoaPods version 1.9.3
[!] Android Studio (not installed)
• Android Studio not found; download from https://developer.android.com/studio/index.html
(or visit https://flutter.dev/docs/get-started/install/macos#android-setup for detailed instructions).
[✓] VS Code (version 1.48.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.14.0
[!] Connected device
! No devices available
I can launch an emulator through the terminal by executing the "emulator -avd flutter_emulator" command and it launches successfully. Then VS Code also detects that emulator and displays it in the devices bar at the bottom part.
The text was updated successfully, but these errors were encountered: