-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Add support for moving symbols across packages with dart fix
#48997
Comments
Do we know who the owner for this item is? We'd like to ship support for this - for tooling to help us roll out the new |
Ah, great to hear! I didn't know this was in progress. |
Yeah. #23067 is I think the blocker for @natebosch's use case. |
See: #48997 Change-Id: Iad16b9eae0523bc4bc14537af642b05efa75b6f7 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246663 Commit-Queue: Phil Quitslund <[email protected]> Reviewed-by: Brian Wilkerson <[email protected]>
This reverts commit 3290d7a. Reason for revert: flutter engine breakage (flutter/flutter#105641) Original change's description: > [data driven] support moving symbols across packages > > See: #48997 > > Change-Id: Iad16b9eae0523bc4bc14537af642b05efa75b6f7 > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246663 > Commit-Queue: Phil Quitslund <[email protected]> > Reviewed-by: Brian Wilkerson <[email protected]> # Not skipping CQ checks because original CL landed > 1 day ago. Change-Id: I4a83d50497d6208b7f518ca1b381ece3aab192ad Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247606 Reviewed-by: Siva Annamalai <[email protected]> Reviewed-by: Keerti Parthasarathy <[email protected]> Commit-Queue: Phil Quitslund <[email protected]> Reviewed-by: Phil Quitslund <[email protected]> Reviewed-by: Brian Wilkerson <[email protected]>
This reverts commit f111a2d. Reason for revert: this change was mistakenly associated w/ a windows bot breakage (flutter/flutter#105641) Original change's description: > Revert "[data driven] support moving symbols across packages" > > This reverts commit 3290d7a. > > Reason for revert: flutter engine breakage (flutter/flutter#105641) > > Original change's description: > > [data driven] support moving symbols across packages > > > > See: #48997 > > > > Change-Id: Iad16b9eae0523bc4bc14537af642b05efa75b6f7 > > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246663 > > Commit-Queue: Phil Quitslund <[email protected]> > > Reviewed-by: Brian Wilkerson <[email protected]> > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Change-Id: I4a83d50497d6208b7f518ca1b381ece3aab192ad > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247606 > Reviewed-by: Siva Annamalai <[email protected]> > Reviewed-by: Keerti Parthasarathy <[email protected]> > Commit-Queue: Phil Quitslund <[email protected]> > Reviewed-by: Phil Quitslund <[email protected]> > Reviewed-by: Brian Wilkerson <[email protected]> # Not skipping CQ checks because original CL landed > 1 day ago. Change-Id: I769dec0d85fc0a41048b21deec0724d8509ef8e9 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248061 Reviewed-by: Brian Wilkerson <[email protected]> Reviewed-by: Keerti Parthasarathy <[email protected]> Commit-Queue: Phil Quitslund <[email protected]>
We are getting things in place to move these APIs from I could add the deprecations soon, but I'd ideally like to have fix support in place when I do. Can this be prioritized? |
@jacob314 How does this prioritize relative to language feature support or analytics work? |
We can use dart-lang/test#1978 to test the implementation when we start on it. The end result should be:
I'm happy to add a dart fix config file to the PR whenever we have an idea of what the syntax will be for this type of move. |
That would be a good fix to have in general, but doesn't require data-driven fix support. Any time there's a The fix doesn't currently exist.
Yes. We always leave import clean-up until the very last pass. It avoids a large number of possible bugs.
That would be really nice. We've talked a few times about ways to update the |
Is this something we can start on soon? We are getting closer to being ready to deprecate the export of |
Do we think it's sufficient for |
I think it is important for the fix to still work after the migration period. Users will encounter documentation that omits the package:matcher import for a long time and LLMs will likely be confused and suggest code that omits the matcher import. |
Hey there, is there a tentative timeline for this? |
@keertip: are you planning to look at this? |
no, had not planned to. |
I don't think we have any timeline for this. It is not in our queue for Q2, but I think we can prioritize it for Q3. Correct me if I'm wrong but it sounds like the remaining AIs are:
I'll note that we do not have a quick fix for
It sounds like it would be a natural step to add a step after import clean-up that adds and removes packages from |
I think we also want support for encoding this in |
Yes, the clean-up-imports pass seems like a good time to update dependencies. We'd need to collect all of the diagnostics used to find the imported packages for which a dependency needs to be added, then de-dup the list of dependencies so that we can build a consistent set of edits, but other than that it sounds reasonable. |
This reverts commit 3c6ceb8. Reason for revert: This breaks flutter tests - running dart fix in the flutter_svg package adds a flutter_svg: any dependency line to pubspec.yaml. Original change's description: > Add a pass to dart fix for pubspec changes > > Fixes #48997 > > Change-Id: I543a550247920e121837f2bc6c75b5c1acecc670 > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/331740 > Commit-Queue: Keerti Parthasarathy <[email protected]> > Reviewed-by: Brian Wilkerson <[email protected]> Change-Id: I38a234b558d03c6c5c6c00f9ea55db7e1fbc7a89 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/332171 Bot-Commit: Rubber Stamper <[email protected]> Reviewed-by: William Hesse <[email protected]> Reviewed-by: Brian Wilkerson <[email protected]> Commit-Queue: Brian Wilkerson <[email protected]>
Changes to dart fix to add missing dependencies to pubspec have landed. |
Possibly a duplicate of #44892, or may also be considered an extension.
We'd like to move some members across packages, and stop exporting others. The user visible changes is that where they previously had a single import to
package:test/test.dart
they will now also need a dependency onpackage:matcher/expect.dart
as well as an extra pubspec dependency.If we can't target the diagnostic about the undefined name for the fix we would be OK with a migration where we mark the exports as deprecated for a while so that the fixes can be applied. We'd need support for deprecating exports in that case. #23067
The text was updated successfully, but these errors were encountered: