Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate flutter/engine to a Dart workspace for Dart/pub packages #147883

Closed
matanlurey opened this issue May 6, 2024 · 1 comment · Fixed by flutter/engine#54232
Closed

Migrate flutter/engine to a Dart workspace for Dart/pub packages #147883

matanlurey opened this issue May 6, 2024 · 1 comment · Fixed by flutter/engine#54232
Assignees
Labels
c: tech-debt Technical debt, code quality, testing, etc. engine flutter/engine repository. See also e: labels. P2 Important issues not at the top of the work list team-engine Owned by Engine team triaged-engine Triaged by Engine team

Comments

@matanlurey
Copy link
Contributor

tl;dr: Dart tooling is landing support for so-called Pub workspaces, the engine should use them when ready.


Right now, flutter/engine has many, many pubspec.yaml file each of which needs to be independently maintained, and comply with our policy of not resolving any packages to external data sources (i.e., all packages have to either be vended by the Dart SDK, or via our own DEPS file).

The impact of this is perhaps most profound when you look at the necessary dependencies needed to use package:test as a dependency, which at the time of this writing, was nearly ~50 packages (and hand-written paths that resolve to different directories depending on the package).

With upcoming pub workspaces, we could instead:

  • Have a single root flutter/engine/pubspec.yaml listing all pub dependencies we use.
  • Have nested packages use resolution: workspace

Unblocks #133569.

See also:

@matanlurey matanlurey added engine flutter/engine repository. See also e: labels. P2 Important issues not at the top of the work list blocked Issue is blocked by another issue c: tech-debt Technical debt, code quality, testing, etc. team-engine Owned by Engine team labels May 6, 2024
@jonahwilliams jonahwilliams added the triaged-engine Triaged by Engine team label May 13, 2024
@matanlurey matanlurey self-assigned this Jun 24, 2024
@matanlurey matanlurey removed the blocked Issue is blocked by another issue label Jun 24, 2024
auto-submit bot pushed a commit to flutter/engine that referenced this issue Jul 18, 2024
... and use it in `engine_tool` to prove everything is working, i.e. on CI and elsewhere.

Partial work towards flutter/flutter#147883.
Supersedes and closes #51782 (which was a prototype).

See also:
- https://flutter.dev/go/pub-workspace, the design doc on the feature.
- dart-lang/pub-dev#7762, an example PR.

I'll probably end up moving the inline docs in `pubspec.yaml` to a `docs/*.md` once that's a thing.
itsjustkevin pushed a commit to itsjustkevin/engine that referenced this issue Jul 19, 2024
…3539)

... and use it in `engine_tool` to prove everything is working, i.e. on CI and elsewhere.

Partial work towards flutter/flutter#147883.
Supersedes and closes flutter#51782 (which was a prototype).

See also:
- https://flutter.dev/go/pub-workspace, the design doc on the feature.
- dart-lang/pub-dev#7762, an example PR.

I'll probably end up moving the inline docs in `pubspec.yaml` to a `docs/*.md` once that's a thing.
matanlurey added a commit to flutter/engine that referenced this issue Jul 27, 2024
Part of flutter/flutter#147883.

Excluding Fuchsia and the Web SDK, the remaining scripts are:

```sh
$ ./tools/find_pubspecs_to_workspacify.sh

/Users/matanl/Developer/engine/src/flutter/impeller/tessellator/dart/pubspec.yaml
/Users/matanl/Developer/engine/src/flutter/sky/packages/sky_engine/pubspec.yaml
/Users/matanl/Developer/engine/src/flutter/shell/vmservice/pubspec.yaml
/Users/matanl/Developer/engine/src/flutter/lib/snapshot/pubspec.yaml
/Users/matanl/Developer/engine/src/flutter/lib/gpu/pubspec.yaml
/Users/matanl/Developer/engine/src/flutter/lib/web_ui/pubspec.yaml
/Users/matanl/Developer/engine/src/flutter/flutter_frontend_server/pubspec.yaml
```

These could be the trickiest, so I'm doing them separately.
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
c: tech-debt Technical debt, code quality, testing, etc. engine flutter/engine repository. See also e: labels. P2 Important issues not at the top of the work list team-engine Owned by Engine team triaged-engine Triaged by Engine team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants