Skip to content

Add automatic launch configurations for detected project/launch types (Flutter, Dart CLI, Test, Dart web)聽#2216

Closed

Description

@isidorn

Hi VS Code dev here 馃憢

Last milestone we have introduced a Start View for debugging. More about this can be found here microsoft/vscode#84677
So when the user has no launch.json file this view should help him start debugging.

This view is currently language agnostic and not very cluttered thus we are slowly looking in opening it up to extensions. We have two options:

  1. Allow extensions to contribute commands / text to the current view. Those commands would be rendered as additional blue buttons or as some menu
  2. Allow extensions to contribute a whole view which would be below the start view. The Dart extension could choose what to render in that view and it would give a bit more control to the extension. Using context keys this view would only be visible in the "start" experience

What I would be interested in is what Dart would like to contribute to improve the start experience. If it is only commands, than I think it makes sense to show those commands in the start view (for example with additional blue buttons). If it is much more then it makes more sense that Dart contributes the whole view.
What are the biggest pain points that Dart users hit when setting up debugging?

Related python discussion: microsoft/vscode-python-debugger#164

Let me know what you think and how you envision the Dart debug start experience.
Thanks!

Current look of debug start view
fyi @DanTup

Screenshot 2020-01-13 at 11 27 54

Activity

  1. added this to the v3.9.0 milestone on Jan 13, 2020
  2. DanTup commented on Jan 13, 2020

    @DanTup
    Member

    @isidorn thanks for the issue! Do you have any suggestions/guidelines for the sort of things we should add here? Generally in Dart we try to make just pressing F5 do the best thing (we have some heuristics to decide between running the app as a Flutter app, running as a Dart CLI script, or running tests, based on project structure, active file, etc).

    Since this only shows up when there is no launch.json it seems like we probably shouldn't do too much here (we don't want functionality that "disappears" when you create a launch.json). I scanned through some of the other issues, but couldn't see any concrete suggestions. It'd be good to have some guidelines (or examples, for ex. for JS/TS) to encourage consistency across languages.

    Thanks!

  3. isidorn commented on Jan 13, 2020

    @isidorn
    Author

    @DanTup thanks for the response and makes sense. We definetely do not want this view cluttereted and we do want consistency. So I suggest that we wait and see what we do for other langugaes before we focus on dart (the out of the box experience might work just fine for you).
    If you get some ideas in the meantime do let us know. Thanks

  4. modified the milestones: v3.9.0, v3.10.0 on Mar 24, 2020
  5. modified the milestones: v3.10.0, v3.11.0 on Apr 21, 2020
  6. modified the milestones: v3.11.0, On Deck on May 18, 2020
  7. modified the milestones: On Deck, v3.13.0 on Jul 2, 2020
  8. DanTup commented on Jul 28, 2020

    @DanTup
    Member

    I took a look at this, and the example at microsoft/vscode#91471 and it looks like there's probably not a lot useful for Dart/Flutter to add here. There's already a debug button and that tends to just do the right thing (it will detect the project type and guess the entry point based on open files or files that follow the pub/Flutter conventions).

    There are some things I think could be useful to add there as buttons, for ex.

    • Run Flutter app
    • Debug Flutter app
    • Run all Tests
    • Debug all Tests

    However, these would need to be dynamic and it doesn't seem like that's possible.

    I did spot a "Show all automatic debug configurations" link though - so it seems we have something to implement there (which could include the options above), so I'll take a look at that (and reuse this issue for that). Thanks!

  9. DanTup commented on Jul 28, 2020

    @DanTup
    Member

    Actually, it looks like microsoft/vscode#95863 might be suggesting showing those from the "automatic" list directly in the view, so we might get the best of both of the above :-)

  10. changed the title [-]Contribute to debug start experience[/-] [+]Add automatic launch configurations for detected project/launch types (Flutter, Dart CLI, Test, Dart web)[/+] on Jul 28, 2020
  11. added
    in debuggingRelates to the debug adapter or process of running debug sessions
    is enhancementAn enhancement or improvement that should be listed in release notes but is not a bug fix.
    and removed on Jul 28, 2020
  12. added a commit that references this issue on Jul 28, 2020
    6635821
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

    in debuggingRelates to the debug adapter or process of running debug sessionsis enhancementAn enhancement or improvement that should be listed in release notes but is not a bug fix.

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions