fix(devtools): fix extension config name and VM service response parsing - #17
Conversation
DrkXo
commented
Oct 1, 2026
- Update extension/devtools/config.yaml name to hyper_render_devtools to match package name and pass DevTools validation.
- Update devtools_ui _call to handle Map, String, or raw responses from VM service.
- Rebuild extension web assets in extension/devtools/build.
- Update extension/devtools/config.yaml name to hyper_render_devtools to match package name and pass DevTools validation. - Update devtools_ui _call to handle Map, String, or raw responses from VM service. - Rebuild extension web assets in extension/devtools/build.
Two bugs kept the DevTools extension from ever working:
- extension/devtools/config.yaml used the display name "HyperRender
Inspector" as `name`; devtools_extensions requires the owning package
name, so validation rejected the extension. Now hyper_render_devtools.
- devtools_ui _call read result.json['result'] as a JSON string, but
vm_service already unwraps the JSON-RPC envelope: result.json IS the
object the extension returned (e.g. {'renderers': [...]}). No payload
has a 'result' key, so every call returned null and the panel always
showed "Could not connect". Return result.json directly.
Verified against a live app via vm_service (listRenderers / getUdt /
getPerformance all return the payload unwrapped). Rebuilt
extension/devtools/build with Flutter 3.41.9 (flutter build web; the
devtools_extensions 0.2.2 build_and_copy passes the removed
--web-renderer flag). `devtools_extensions validate` passes. Adds a
test pinning config name == package name.
Builds on the first fix in this PR; replaces its prebuilt assets with a
maintainer rebuild and simplifies _call (the Map/String branches never ran).
Co-authored-by: DrkXo <chayantaposh@gmail.com>
|
Thank you @DrkXo — great catch, and a real one: the inspector had never been able to connect. I verified both bugs against a live app:
I pushed one maintainer commit on top of yours:
Squash-merging with you as author. It will ship in the next |
|
Thank you! 🙏 really appreciate you taking the time to verify everything and clean this up. I’m glad the issues were tracked down and fixed properly. I’m currently working on a separate fork/branch for [Readaway], which needed a couple of core changes:
I kept these changes separate for now since they were needed for my project. If you think they would be useful in Thanks again for the review and for keeping the attribution/credit. Really appreciate it! 🙏 |
|
Thanks a lot for the kind words, and for the fixes in this PR! 🙏 Yes please, those 2 fixes would be useful upstream. Could you open a separate PR from the latest main (it has 1.10.0 now)? Only these commits + the test file: Please leave out the devtools build files, they will conflict with the DevTools v2 we just merged. Few small things before merge:
Your authorship stays, of course. Thanks again! |