Skip to content

Improve setPubRootDirectories api #105730

@CoderDake

Description

@CoderDake

Currently setPubRootDirectories replaces the entire set of pubRoot Directories. So the caller can run into race conditions where another caller has changed the pubroot directories, since the last time getPubRootDirectories were called.

To allow for more flexible and safe interaction with pubRootDirectories, change the API to have addPubRootDirectories(List<String>) and removePubRootDirectories(List<String>).

Then change setPubRootDirectories so that it actually wraps addPubRootDirectories and add a deprecation notice to the function

Metadata

Metadata

Assignees

Labels

P3Issues that are less important to the Flutter projectc: proposalA detailed proposal for a change to Flutterf: inspectorPart of widget inspector in framework.frameworkflutter/packages/flutter repository. See also f: labels.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions