Skip to content

Provide a vmservice method for getting the package config url for an isolate(group) #56784

Open
@sigurdm

Description

@sigurdm

There seems to be no such method yet

Currently devtools is jumping through a lot of hoops to do this. It looks for package configs from the library containing the main file of the current root isolate.

This is not always correct (the main file might be exported from an imported package)

Also finding the .dart_tool/package_config.json via the dtd protocol is also troublesome, given that it has limited file access (cannot reach files outside the IDE root, which is not guaranteed to contain the package config if the ide is scoped to only parts of a pub workspace.)

Here is the current code:

https://github.com/flutter/devtools/blob/b77c98038700521c4b6da9183fd356674bd42a1a/packages/devtools_shared/lib/src/utils/file_utils.dart#L31

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.triagedIssue has been triaged by sub teamtype-enhancementA request for a change that isn't a bugvm-serviceThe VM Service Protocol, both the specification and its implementation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions