flutter / flutter/devtools

In tests, on Windows & WSL, devtools extension doesn't load first time, fails when loading the second time

未关闭
#8,912 21 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
bug devtools extensions P1 product-quality
主要语言
Dart
星标
1.7k
派生
404
平均合并
6 天 17 小时
30 天内合并 PR
18

描述

The latest version of the ROHD package on `main` (https://github.com/intel/rohd) has a functioning devtools extension when run in the virtual environment, and we have flutter tests passing as well. We have an `artifacts` branch (https://github.com/intel/rohd/tree/artifacts) which (via GitHub actions) contains the built devtool extension in the proper location.

We cannot get the devtool extension to open properly after it has been built. A few datapoints:

- When we build the devtools extension locally, and point to it, then open devtools, chrome freezes, and we can't get to any debug console.
- When we point to a git path in pubspec.yaml (`artifacts` branch) with build available, and run a test, and we do Command Pallette > "Open Devtools in Browser", the "rohd" extension tab is not visible.
- When we point to a git path with build available, and run a test, and we do Command Pallette > "Open Devtools" > "In Web Browser" (note the difference from the previous bullet), the "rohd" extension is visible, but cannot enable the extension. Clicking the enable button seems to trigger some API to localhost, but to no effect.
- When we point to a git path with build available, and run an example (from example/ directory), and we do Command Pallette > "Open Devtools" > "In Web Browser" OR Command Pallette > "Open Devtools in Browser", chrome opens but then the debug session immediately ends and the devtools extension does not connect.

An example repo you could use is rohd-hcl (https://github.com/intel/rohd-hcl) which depends on rohd. For the extension to fully be functional, you'd just need to set a breakpoint after some `.build()` step in a test or example -- but we haven't even gotten to the point where any of the UI loads anyways yet.

We've tried running with:
- Dart 3.7.0 on WSL2 on Windows 11
- Flutter 3.29.0 on Windows 11

We use Visual Studio Code.

We're happy to provide any additional details to help. All our source code to reproduce is available in the repos mentioned, including the rohd package, the rohd devtools extension, and rohd-hcl as a package that depends on rohd.

Tagging @kenzieschmoll @DanTup, since they were helpful last time we were trying to get this all working :)

___
**DevTools version**: 2.42.2
**IDE**: VSCode

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。