-
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
[breaking change]: Deprecation and discontinuation of standalone Dart tools #46100
Comments
Related to: #46100 Change-Id: I2bcd4aadfbc96fa6ba265aec04cd60e3e81eef41 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/199429 Commit-Queue: Michael Thomsen <[email protected]> Reviewed-by: Martin Kustermann <[email protected]> Reviewed-by: Ben Konyi <[email protected]> Reviewed-by: Devon Carew <[email protected]>
I can begin switching the flutter usages of the tools with specified deprecation dates. For some of these, it seems like there is still a significant gap in functionality (analysis server usage with dart analyze, or the various compile options for dart2js). Is there a plan to resolve this before announcing deprecation dates? |
I can at least speak for the dart2js side, yes. We will ensure there isn't any gap in our case. It's very likely that we'll even preserve all existing flags, but we'll confirm once the plan is finalized. |
The items marked as deprecated in 2.14 in the table are considered "feature complete" and we're not aware of any things missing from them. For |
what is the replacement for the web-angular which is in now in stagehand? |
As angular-dart is also being discontinued, most probably dart create will not include web-angular template. But Is the google team planning to release a separate CLI tool for angular-dart or there are other existing alternatives? Update: I found one https://pub.dev/packages/ngdart |
|
@mit-mit I'm thinking of functionality like the lsp mode that the analysis server supports, unless that snapshot won't be removed. |
The analysis server snapshot won't be going anywhere any time soon since we don't have a replacement for it in the CLI. |
ack, I actually forgot about dartanalyzer, but that one makes more sense 😅 |
As of this CL, dartfmt is now printing a deprecation notice. |
To anyone else also stumbling across this, my solution was to add a |
@simolus3 - can you open an issue against https://github.com/dart-lang/dartdoc for the dartdoc CLI flags you're missing? And, have you tried configuring dartdoc via the dartdoc_options.yaml file (https://github.com/dart-lang/dartdoc#dartdoc_optionsyaml)? That allows you to tweak more parameters than are available through |
This completes the breaking change that was previously announced in #46100 Change-Id: Ie81665e7932fe00a8c1fee9f67ee8294cd4c89e9 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248342 Reviewed-by: Joshua Litt <[email protected]> Commit-Queue: Sigmund Cherem <[email protected]> Reviewed-by: Nicholas Shahan <[email protected]>
We recently had dart-lang/build#3337 filed on package:build, I was wondering if I can get some clarification here, as currently Will it be safe to continue using these snapshots in perpetuity, or is there a plan to delete them? If we do delete them, how should we invoke DDC? It does look like for |
@jakemac53 - yes, the goal is still to support their use from build_web_compilers. For now we intend to keep the snapshots, but there have been discussions about combining the snapshots into the CLI snapshot sometime in the future (but that's not a short term goal). To avoid the warning, using As for DDC, the snapshot will remain available for foreseeable future. Note that DDC should not give you a warning if you are using the snapshot (only the shell script does today). |
Thanks, I will go ahead and land the change to use |
These discontinuations are now complete, and the current dev channel build (
|
Background
Historically the Dart team has offered a number of smaller developer tools for things like formatting code (
dartfmt
), analyzing code (dartanalyzer
), etc. In Dart 2.10 (October 2020) we introduced a new unified Dart developer tool, thedart
tool.Intended change
As we discussed at launch in the blog post, we plan to first deprecate and then discontinue the smaller tools in favor of the new combined tool. The this meta-bug presents an overview of the status of this migration. As this is considered breaking, it will happen in a staged fashion over time, when each individual tool first becoming deprecated in one stable release (here it will still exist but print a warning), and then fully discontinued (here it will no longer be in the SDK).
dart
replacementstagehand
dart create
dartfmt
dart format
dart2native
dart compile exe
dart2js
dart compile js
dartdevc
dartanalyzer
&package:analyzer_cli
dart analyze
dartdoc
dart doc
pub
dart pub
Notes:
dartaotruntime
.stagehand
will go directly to discontinuation as it's apub global
tool on pub.dev, and not a SDK distributed tool like the rest. This means it can still be invoked (withdart pub global run stagehand
) even after it's been discontinued.dartdevc
will be discontinued as a publicly visible tool. The tool was never intended or supported as a stable command line tool for end users. The underlying binary for this compiler will still be shipped with the SDK to be used by build systems tools (such as bazel,webdev
, andflutter_tools
). However, it will no longer be exposed to be used by developers directly on the command line.Rationale
With the new unified tool the existing tools are no longer needed. To reduce maintenance, remove confusion for new users, and to ensure we offer a single high-quality toolset the old commands are being removed.
Should you have any issues with missing functionality in the new
dart
-based tools, please file an issue.Migration
To migrate, switch to using the
dart
tool, and the subcommands listed in the above table.The text was updated successfully, but these errors were encountered: