Skip to content

This debug session is not ready yet , but my app is lunched from debug config vscode  #4987

Closed as not planned

Description

@heshesh2010

when run my flutter app using debug mode on real ios device , the app is lunched and working , but the debug session is not linked to device , and when I try to open inspect widget i got this message : "This debug session is not ready yet." and stuck in this phase

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.16.9, on macOS 14.3.1 23D60 darwin-x64, locale en-EG)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 15.2)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2022.3)
[✓] VS Code (version 1.86.1)
[✓] Connected device (3 available)
[✓] Network resources

• No issues found!

Activity

  1. DanTup commented on Feb 15, 2024

    @DanTup
    Member

    Could you confirm:

    • Exactly how you're launching the app (what button/key are you pressing?)
    • What kind of run is it (debug/profile/release)?
    • What version of the Dart extension do you have?
    • Whether you have the dart.useLegacyDebugAdapters setting set in VS Code
    • What the last output in the Debug Console is after the app launches
    • Whether other functionality such as Hot Reload is working

    Could you also confirm whether this only happens on your physical device, or whether you can also reproduce on the simulator?

    Thanks!

  2. added
    awaiting infoRequires more information from the customer to progress
    on Feb 15, 2024
  3. heshesh2010 commented on Feb 15, 2024

    @heshesh2010
    Author

    @DanTup

    Exactly how you're launching the app (what button/key are you pressing?)
    hit play button in vs code in run and debug panel .

    What kind of run is it (debug/profile/release)?
    debug

    What version of the Dart extension do you have?
    v3.82.0

    Whether you have the dart.useLegacyDebugAdapters setting set in VS Code
    no, this setting is not exits in setting file

    What the last output in the Debug Console is after the app launches

    here is , but pls note that i still got message Flutter: Lanching...

    but my app already works .

    Launching lib/main.dart on hesham’s iPhone in debug mode...
    Automatically signing iOS for device deployment using specified development team in Xcode project: RZ96H224UQ
    Xcode build done. 255.7s
    You may be prompted to give access to control Xcode. Flutter uses Xcode to run your app. If access is not allowed, you can change this through your Settings > Privacy & Security > Automation.
    Connecting to the VM Service is taking longer than expected...
    Still attempting to connect to the VM Service...
    If you do NOT see the Flutter application running, it might have crashed. The device logs (e.g. from adb or XCode) might have more details.
    If you do see the Flutter application running on the device, try re-running with --host-vmservice-port to use a specific port known to be available.

    Whether other functionality such as Hot Reload is working?
    when i press hot reload the previous logs got cleared , and I got this new logs and nothing happens :

    Exception attempting to connect to the VM Service: SocketException: Connection refused (OS Error: Connection refused, errno = 61), address = 192.168.100.8, port = 51501
    This was attempt #50. Will retry in 0:00:01.600000.

    Could you also confirm whether this only happens on your physical device, or whether you can also reproduce on the simulator?

    Yes it works on iphone sumilator ios iphone 15 .

    Thanks!

  4. DanTup commented on Feb 15, 2024

    @DanTup
    Member

    Exception attempting to connect to the VM Service: SocketException: Connection refused (OS Error: Connection refused, errno = 61), address = 192.168.100.8, port = 51501

    This looks like the problem - it seems like we're not connected to the VM service correctly. Could you:

    • confirm which iPhone and iOS version you're using
    • provide a copy of your pubspec.yaml that lists all packages you use
    • if possibly, try with a different USB cable to see if that makes any difference

    Can you also confirm whether this happens only with this particular app, or do you see the same if you create a new counter app (using the Flutter: New Project command)

  5. heshesh2010 commented on Feb 15, 2024

    @heshesh2010
    Author

    Exception attempting to connect to the VM Service: SocketException: Connection refused (OS Error: Connection refused, errno = 61), address = 192.168.100.8, port = 51501

    This looks like the problem - it seems like we're not connected to the VM service correctly. Could you:

    • confirm which iPhone and iOS version you're using
    • provide a copy of your pubspec.yaml that lists all packages you use
    • if possibly, try with a different USB cable to see if that makes any difference

    Can you also confirm whether this happens only with this particular app, or do you see the same if you create a new counter app (using the Flutter: New Project command)

    confirm which iPhone and iOS version you're using : iphone 14 pro max , ios 17.3.1

    provide a copy of your pubspec.yaml that lists all packages you use

    `.   ---
    name: siyaq
    description: A new Flutter project.
    publish_to: none
    #version: 3.1.6+37
    version: 6.3.9+70
    environment:
      sdk: ">=2.19.2 <4.0.0"
    dependencies:
      flutter:
        sdk: flutter
      go_sell_sdk_flutter: ^2.3.5
      timezone: ^0.9.1
      html: ^0.15.1
      flutter_widget_from_html: ^0.14.11
      socket_io_client: ^2.0.0
      agora_rtc_engine: ^6.2.6
      permission_handler: ^11.0.1
      iban: ^1.0.1
      keep_screen_on: ^3.0.0
      path_provider: ^2.0.8
      stop_watch_timer: ^3.1.0+4
      webview_flutter: ^4.4.4
      simple_gesture_detector: ^0.2.0
      omni_datetime_picker: ^1.0.7
      firebase_core: ^2.25.0
      url_launcher: ^6.1.10
      uni_links: ^0.5.1
      material_design_icons_flutter: ^7.0.7296
      roundcheckbox: ^2.0.4+1
      pin_input_text_field: ^4.1.1
      cupertino_icons: ^1.0.2
      flutter_screenutil: ^5.8.1
      introduction_screen: ^3.0.0
      easy_localization: ^3.0.0
      flutter_svg: ^2.0.5
      group_button: ^5.3.2
      flutter_staggered_grid_view: ^0.7.0
      parsed_readmore: ^0.0.6
      flutter_slidable: ^3.0.0
      percent_indicator: ^4.0.0
      dotted_border: ^2.0.0+2
      flutter_rating_bar: ^4.0.1
      pinput: ^3.0.0
      im_stepper: ^1.0.1+1
      linear_progress_bar: ^1.1.0
      gender_picker: ^1.1.0
      flutter_datetime_picker:
        git:
          url: https://github.com/HasanAlqaisi/flutter_datetime_picker.git
      badges: ^3.0.2
      get: ^4.6.6
      cached_network_image: ^3.3.1
      loading_animation_widget: ^1.2.0+1
      flutter_custom_clippers: ^2.0.0
      syncfusion_flutter_datepicker: ^24.1.46
      numberpicker: ^2.1.1
      shimmer: ^3.0.0
      country_ip: ^3.0.0
      flutter_reaction_button: ^3.0.0+3
      photo_view: ^0.14.0
      carousel_slider: ^4.1.1
      pull_to_refresh: ^2.0.0
      file_picker: ^6.1.1
      share_plus: ^7.2.2
      universal_platform: ^1.0.0+1
      collection:
      connectivity_plus: ^5.0.0
      app_settings: ^5.0.0
      screenshot: ^2.1.0
      popover: ^0.3.0
      transparent_image: ^2.0.1
      wechat_camera_picker: ^4.2.0-dev.3
      photo_manager: ^3.0.0-dev.4
      flutter_spinkit: ^5.2.0
      rounded_loading_button: ^2.1.0
      photo_manager_image_provider: ^2.1.0
      timeago: ^3.6.1
      animated_bottom_navigation_bar: ^1.3.3
      gradient_borders: ^1.0.0
      jwt_decoder: ^2.0.1
      video_trimmer: ^3.0.1
      firebase_messaging: ^14.6.9
      equatable: ^2.0.5
      better_player:
        git:
          url: https://github.com/heshesh2010/better_player
      shared_preferences: ^2.0.13
      encrypt: ^5.0.3
      flutter_branch_sdk: ^7.0.2
      image_cropper: ^5.0.0
      notification_permissions: ^0.6.1
      flutter_photo_editor:
        git:
          url: https://github.com/heshesh2010/flutter_photo_editor
      wechat_assets_picker: ^9.0.0-dev.2
      flutter_linkify: ^6.0.0
      get_it: ^7.6.0
      infinite_scroll_pagination: ^4.0.0
      http_interceptor:
        git:
          url: https://github.com/Getdriven/http_interceptor.git
          ref: feature/pool-manager
      pool: ^1.5.1
      loader_overlay: ^4.0.0
      device_preview: ^1.1.0
      image_pixels: ^3.0.2
      firebase_crashlytics: ^3.4.9
      flutter_video_info: ^1.3.1
      flutter_facebook_auth: ^6.0.4
      simple_gradient_text: ^1.3.0
      flutter_volume_controller: ^1.3.1
      sound_mode: ^3.0.0
      real_volume: ^1.0.7
    dev_dependencies:
      flutter_test:
        sdk: flutter
      flutter_launcher_icons: ^0.13.1
      flutter_native_splash: ^2.3.6
      flutter_sticky_header: ^0.6.5
      intrinsic_dimension: ^0.3.1
    dependency_overrides:
      intl: ^0.18.0
      extended_image: ^8.0.1
      http: ^0.13.3
      flutter_widget_from_html_core: ^0.14.11
      win32: ^5.0.6
    flutter_icons:
      android: true
      ios: true
      image_path: assets/images/ios_logo.png
      flutter_lints: ^2.0.0
    flutter:
      uses-material-design: true
      assets:
        - assets/images/
        - assets/images/flags/
        - assets/svg/
        - assets/fonts/
        - shorebird.yaml
      fonts:
        - family: IBMPlexSansArabic
          fonts:
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-Thin.ttf
              weight: 100
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-ExtraLight.ttf
              weight: 200
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-Light.ttf
              weight: 300
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-Regular.ttf
              weight: 400
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-Medium.ttf
              weight: 500
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-SemiBold.ttf
              weight: 600
            - asset: assets/fonts/IBM_Plex_Sans_Arabic/IBMPlexSansArabic-Bold.ttf
              weight: 700
    
    flutter_native_splash:
      color: "#D5D100"
    
      android: true
      ios: true
      fullscreen: false
      android_12:
        color: "#D5D100"
     `    )
    
    

    please note that , the bug i fixed when i restarted my phone , and this bug may occurs multiple times with same usb cable , and sometimes it works without bugs .

  6. DanTup commented on Feb 15, 2024

    @DanTup
    Member

    Thanks - some of the issues I linked above also seem to be related to Firebase, but it's not clear to me if that's related.

    If the issue only occurs sometimes, then it could be something like a bad USB cable - do you have another you can try with?

    I don't think there's any issue here in the Dart extension though, as the connection is all handled by Flutter. You will likely see similar errors when running from the terminal with flutter run. Unfortunately VS Code can't work correctly without a connection to the VM Service (which is provided by Flutter).

    I would first try with another cable, and if that doesn't solve the issue I would read through some of the issues linked above to see if there are any solutions there.

    Otherwise, it would be best to file at https://github.com/flutter/flutter/ since the error message is coming from Flutter and not something the VS Code extension would be able to fix.

    Thanks!

  7. github-actions commented on Mar 7, 2024

    @github-actions

    This issue has been marked stale because it is tagged awaiting-info for 20 days with no activity. Remove the stale label or comment to prevent the issue being closed in 10 days.

  8. JamesHancockAtteria commented on Sep 10, 2026

    @JamesHancockAtteria

    Please reopen this. It's still an issue. IN my case it's using the web head with wasm debug.

  9. DanTup commented on Sep 10, 2026

    @DanTup
    Member

    @JamesHancockAtteria please open a new issue and include details about the SDK versions you're on, the behaviour you're seeing, and how to reproduce. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    awaiting infoRequires more information from the customer to progressis bugstaleWill be closed soon if no response.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions