Commit Graph

105 Commits

Author SHA1 Message Date
pq 1d7eb3f7d2 pluralize fix summary
Fixes: https://github.com/dart-lang/sdk/issues/43870

Change-Id: I871f556200323128b4c63368acf61ebec4e97696
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/168680
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2020-10-21 14:44:13 +00:00
Ben Konyi 07ce8486a6 [ Dart CLI ] Fix issue where -D was not being accepted by 'dart run'
Fixes https://github.com/dart-lang/sdk/issues/43779

Fixed: 43779
Change-Id: I886db8014cc3ea1f870974a21a552d7983b6b408
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167700
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-10-16 00:53:21 +00:00
pq 24052b0660 canonicalize input path for reporting
Fixes: https://github.com/dart-lang/sdk/issues/43792

Change-Id: Ief28d857243eb2859aa5d2e34815dcc156799d28
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167726
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2020-10-14 22:15:48 +00:00
Devon Carew f6460afd98 refactor AnalysisServer wrapper class
Change-Id: Ia078bae38fb0318e34f6e61753e3429934b2fd2f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166800
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Jaime Wren <jwren@google.com>
2020-10-09 19:56:17 +00:00
Devon Carew 4d7714174e [dartdev] push the analysisFinished logic down into the AnalysisServer wrapper
Change-Id: Idf2c7422046365bae056c8c767ed915ad91d7cf2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166560
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-10-07 22:58:06 +00:00
pq f122752b99 display progress while fixing and display a count summary on exit
Sample output:

[~/src/repos/dart/sdk/pkg/analyzer] (master) $ dart ../dartdev/bin/dartdev.dart fix

*** The `fix` command is provisional and subject to change or removal in future releases. ***

Computing fixes in analyzer...         43.8s
Applying fixes...                      15.5s
Fixed 359 files.



Fixes: https://github.com/dart-lang/sdk/issues/43569

Change-Id: Ief3c9edf578f74413352cdd0a8d84996b1de05f0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166302
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2020-10-07 05:14:03 +00:00
pq 0ecf73a301 wait for server shutdown (to prevent early termination)
Fixes: https://github.com/dart-lang/sdk/issues/43568


Change-Id: Ib9e8ac2ffaa3c37a77c913524ae455b134daa46d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166120
Reviewed-by: Devon Carew <devoncarew@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2020-10-06 16:55:53 +00:00
Ben Konyi 0732bac32c [ DartDev ] Fix issue where --help after a script name would be
interpreted by 'dart run'

Would prevent scripts from accepting their own '--help' option when
running with DartDev.

Fixes https://github.com/dart-lang/sdk/issues/43487

Change-Id: I5fca196529ae7670ee6a7c37701a5fffdad11aa1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/164605
Reviewed-by: Janice Collins <jcollins@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-09-28 17:00:26 +00:00
Ben Konyi fe85812e27 [ VM / DartDev ] Fix --disable-service-auth-codes not being recognized by DDS
The VM and dartdev were not forwarding --disable-service-auth-codes to
the DDS instance, resulting in auth codes always being enabled.

Change-Id: Ib23bfeb7c64a51fb1229f049a4b61cb1ce5018de
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/163261
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-09-18 17:23:31 +00:00
Jaime Wren 743a1d0b52 [dartdev] Reimplement the dartdev analytics with events and custom dimensions, matching the flutter cli analytics patterns where possible
Bug: https://github.com/dart-lang/sdk/issues/43198
Change-Id: Iff3ac619965142c10864559ff396b64130f18daf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161200
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2020-09-09 18:10:49 +00:00
Devon Carew b3930c3ded [dartdev] add custom help messages to 'dart test' when package:test is not available
Change-Id: I536b4068319b785bb4ac2e8ccceb7df4c67c30e5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161763
Reviewed-by: Jaime Wren <jwren@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-09-03 22:06:45 +00:00
Ben Konyi f0d88cc96d Reland "[ Service / DDS ] Advertise DDS as the VM service, bump version to 4.0"
This reverts commit ed120c3c80.

Change-Id: I445f4bb2dafaad3ce2daa3ae42efe1723f9b1abe
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160660
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-09-03 15:20:14 +00:00
Devon Carew 2e76fecacb [dartdev] a few more updates to the dartdev tool help
Change-Id: I40beba78d27cf20d282b8551eda2654653637b12
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161182
Reviewed-by: Kathy Walrath <kathyw@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-08-31 22:31:40 +00:00
Devon Carew f81dadfa32 [dartdev] update the help text for dartdev and related commands
Change-Id: Ia7139b109872575e58fa8f1cbc4aa72bef44bee5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161020
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-08-31 20:17:48 +00:00
Michael Thomsen cb39018489 Fix terminology
Related to https://github.com/dart-lang/sdk/issues/42136

Followup to https://dart-review.googlesource.com/c/sdk/+/149595/1

Change-Id: I9427374434d9d38c6b83f71466445edf6db5ea02
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161107
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Michael Thomsen <mit@google.com>
2020-08-31 13:16:08 +00:00
Devon Carew 6285ddc4fa [dartdev] print usage when no file is provided for dart run; re-generate the readme
Change-Id: I6ce61c5343e2274c92b9e7076c8f318cfa3c2388
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160922
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
Reviewed-by: Jaime Wren <jwren@google.com>
2020-08-28 21:35:18 +00:00
Brian Wilkerson 8d3c05f550 Improve indentation for the output of the dart analyze command
Change-Id: If248d3994c8081f60d42dbbbe92f4c9e5dbfbb34
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160923
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Reviewed-by: Jaime Wren <jwren@google.com>
2020-08-28 20:43:48 +00:00
Jaime Wren 2ca30d8d19 Dartdev bug fix, this fixes https://github.com/dart-lang/sdk/issues/43238
Bug: https://github.com/dart-lang/sdk/issues/43238
Change-Id: I166b8c24b7ba708d619fd33415c18220eae6dc58
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160882
Auto-Submit: Jaime Wren <jwren@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
2020-08-28 18:21:48 +00:00
Brian Wilkerson 455bef7cb2 Fix an NPE in verbose mode when there are no context messages
Bug: https://github.com/dart-lang/sdk/issues/43239
Change-Id: I25ec04cce71533fb9bf061d36c405c1131009be1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160881
Reviewed-by: Jaime Wren <jwren@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2020-08-28 18:12:08 +00:00
Devon Carew 7e0412a68c [dartdev] adjust some error output and help text
Change-Id: I6170c3c53cb1b6c293cd53a4c0890b7bff9c7b44
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160784
Reviewed-by: Michael Thomsen <mit@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-08-28 16:01:48 +00:00
Devon Carew b605afe53a [dartdev] some refactoring to the ArgParser handling code in dartdev
Change-Id: I727561cf542023426aa4f8a31427d951127c4f66
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160703
Reviewed-by: Jaime Wren <jwren@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-08-27 20:32:07 +00:00
Jaime Wren 158a470b0c Configure all ArgParsers in dartdev to have consistent usageLineLengths.
Change-Id: Ia69ae2efb280b6875bb769d1f3bbb91b64e50a14
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160380
Commit-Queue: Jaime Wren <jwren@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Auto-Submit: Jaime Wren <jwren@google.com>
2020-08-27 17:50:47 +00:00
Jaime Wren 9c6b639382 Remove the current support dartdev analytics support for reporting flags used
Bug: https://github.com/dart-lang/sdk/issues/43198
Change-Id: I212f8508614876d926b35cf199499bce783a196d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160360
Auto-Submit: Jaime Wren <jwren@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
2020-08-26 20:32:25 +00:00
Devon Carew 504195907b [dartdev] don't expose the 'dart migrate' command on the stable channel
Change-Id: I95d5d9dd74e488c749f17fd358d20188de32866c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160184
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Jaime Wren <jwren@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2020-08-26 17:42:55 +00:00
Ben Konyi ed120c3c80 Revert "[ Service / DDS ] Advertise DDS as the VM service, bump version to 4.0"
This reverts commit 0ea18ffb36.

Reason for revert: Tree is on fire

Original change's description:
> [ Service / DDS ] Advertise DDS as the VM service, bump version to 4.0
> 
> This change does the following:
>   - The DDS URI will be reported by the VM as the VM service URI. If DDS
>     disconnects, the VM service URI will be reported instead. This only
>     impacts the standalone VM.
>   - Updated the service protocol to 4.0 and removed the following
>     deprecated functionality:
>       - Client synchronization RPCs (these now live in DDS)
>       - getWebSocketTarget (no longer needed as the VM service no longer
>         tries to redirect web socket clients to DDS)
>   - Regenerates package:vm_service based on the new spec, prepare for
>     5.0 release
> 
> Change-Id: I8a2b401062342eb99b81ef10ef6926baa88f946e
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160141
> Reviewed-by: Siva Annamalai <asiva@google.com>

TBR=bkonyi@google.com,rmacnak@google.com,asiva@google.com

Change-Id: I6a16e9fa7ceb18555d6424a169cfa811d3833419
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160340
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-08-26 16:08:27 +00:00
Ben Konyi 0ea18ffb36 [ Service / DDS ] Advertise DDS as the VM service, bump version to 4.0
This change does the following:
  - The DDS URI will be reported by the VM as the VM service URI. If DDS
    disconnects, the VM service URI will be reported instead. This only
    impacts the standalone VM.
  - Updated the service protocol to 4.0 and removed the following
    deprecated functionality:
      - Client synchronization RPCs (these now live in DDS)
      - getWebSocketTarget (no longer needed as the VM service no longer
        tries to redirect web socket clients to DDS)
  - Regenerates package:vm_service based on the new spec, prepare for
    5.0 release

Change-Id: I8a2b401062342eb99b81ef10ef6926baa88f946e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160141
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-08-26 14:55:15 +00:00
Jaime Wren 2d931c32e6 Fix in dartdev to enable the query of help output for pub subcommands
Bug: https://github.com/dart-lang/sdk/issues/42965
Change-Id: Id2446b88fb983607f841c2fda81434087dc71d62
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/159341
Commit-Queue: Jaime Wren <jwren@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
2020-08-25 22:27:43 +00:00
Devon Carew 0b2da6e7ef [dartdev] fix dart create and improve the tests.
Change-Id: If949a0f50e3b37619df9051c1ab892e77cb5a391
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160142
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
Reviewed-by: Jaime Wren <jwren@google.com>
2020-08-25 20:40:03 +00:00
Ben Konyi d11e89f516 [ Service ] Wait for DDS connection before outputting service connection
information

When dartdev and the VM service are enabled, the service should avoid
advertising its connection information until after DDS has connected in
order to prevent race conditions between DDS and external clients.

Fixes https://github.com/dart-lang/sdk/issues/42727

Change-Id: If6393f085e9147af628997a1f8936e84f9d8310c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/157462
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-08-20 19:00:59 +00:00
Devon Carew da2bff9c96 update the dartdev pubspec file; various lint fixes
Change-Id: Ib4bc6af7f77001895cbc534ef64c6d999008695f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/159160
Reviewed-by: Jaime Wren <jwren@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2020-08-18 17:12:45 +00:00
Jaime Wren 90756064f9 If the machine is a bot such as a CI machine, prevent the 'The Dart tool uses Google Analytics to anonymously report feature usage...' message from being printed from dartdev.
Bug: https://github.com/dart-lang/sdk/issues/43046
Change-Id: I63c1d73bfd31af14e0a93669a43994222e2f3a50
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/158920
Reviewed-by: Jonas Jensen <jonasfj@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2020-08-18 17:04:40 +00:00
Jaime Wren 538e2e4778 Include a simple README.txt in $HOME/.dart
Fixes https://github.com/dart-lang/sdk/issues/42500

Change-Id: Iec9c6dd3d7c279ddd5eb9ba7fdb934ecd712ad69
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/158521
Reviewed-by: Michael Thomsen <mit@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2020-08-17 22:01:35 +00:00
Jaime Wren 7fa6490ed4 Copy the dart:test ArgParser from https://github.com/dart-lang/test/ to dartdev to have the dart test --help / dart help test command return faster and in a more robust manner.
Bug: https://github.com/dart-lang/sdk/issues/42014
Change-Id: Icb088f9d4756c7673751ebf271575abf05660983
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/158701
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2020-08-17 18:28:59 +00:00
Jaime Wren dec0a1857c Dartdev change to detect stdout.hasTerminal as a new requirement- until the disclosure is shown, with hasTerminal, analytics won't be enabled
Change-Id: I525da104105b01dd0e2669d41c05b6101bb28321
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/158202
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2020-08-14 19:27:19 +00:00
Ben Konyi df18aaa460 [ dartdev ] Set run command help message width to match terminal size
Change-Id: Icd23bcd0993da30266574ad5f4d17c06ba95b364
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/158400
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-08-14 16:21:08 +00:00
Zichang Guo 45643c26f5 add comments dartdev run
Resolve the comment of https://dart-review.googlesource.com/c/sdk/+/157107

Change-Id: I328d55a95f876651e9864d8634edd184601556ec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/157661
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Zichang Guo <zichangguo@google.com>
2020-08-13 23:48:52 +00:00
Ben Konyi 7a8b267a39 [ dartdev ] Set maximum help message character width to 120 characters
Fixes https://github.com/dart-lang/sdk/issues/42964

Change-Id: Ib05b030e71b0fb266b1952b8c2a45eb7f96cfd76
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/158065
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Reviewed-by: Jaime Wren <jwren@google.com>
2020-08-11 00:10:04 +00:00
Ben Konyi 507ffcfdaf [ DartDev ] Fixed issue where flags passed after the script name when
using 'dart run' would be interpreted by the 'dart run' argument parser

Fixes https://github.com/dart-lang/sdk/issues/42941

Change-Id: I46d7654d62b4575f0684f7faae51d972ac5f7f8c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/157542
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-08-06 19:49:02 +00:00
Ben Konyi 31257927e3 [ DartDev ] Add kernel subcommand for compile command
This change adds support for generating simple kernel files. More exotic
kernel generation can still be done using the gen_kernel script.

Fixes https://github.com/dart-lang/sdk/issues/42602

Change-Id: If5f281770dada4a81d85d81d2c36439174540724
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/153389
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-08-05 21:25:39 +00:00
Zichang Guo 79a9e3b54a Fix failing dartdev run test on pkg win
Uri.toFilePath() might throw errors. If it failed, we should fall back
to use file path and try it a try. This fixes the current red pkg win
bot caused by https://dart-review.googlesource.com/c/sdk/+/156922.

Change-Id: Id67723041d222f477d7584fb73a0d77eb91cd41c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/157107
Reviewed-by: Zichang Guo <zichangguo@google.com>
Commit-Queue: Zichang Guo <zichangguo@google.com>
2020-08-05 06:37:10 +00:00
Zichang Guo d4e5212c4d dartdev run commands with file uris
Dart executable accepts a File uri (File://dir/name.dart) as an input,
dartdev run should have the same behavior.

Change-Id: I265ef8242314dbb41c5735c65ee203bbbf76f78e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156922
Commit-Queue: Zichang Guo <zichangguo@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2020-08-05 03:06:40 +00:00
Ben Konyi 501c807266 [ VM / DartDev ] Update argument handling for 'run' command
Previously the help messages for 'dart run' were output by a secondary
VM spawned solely to print the VM's help message. However, this help
message was not consistent with those found for other DartDev commands.

With this change, the 'run' command:

- Uses package:args to create a help message consistent with other
 DartDev commands.

- No longer accepts arbitrary options and is instead restricted to a
 subset of common flags. Passing a VM flag which is not included in
 this subset of commands will result in an argument error if passed
 *after* the 'run' command. Other VM flags can be passed immediately
 following 'dart' and before the DartDev command.

- No longer outputs the VM verbose options when invoked with '--help
 --verbose'. VM verbose options and the original VM help message can
 be viewed by running 'dart --help --verbose'. This makes uncommon
 VM flags used for development less visible to regular users.

- Now properly forwards the subset of VM options accepted by 'run' to
 the VM (e.g., 'dart run --observe --no-pause-isolates-on-exit foo.dart'
 would have ignored '--no-pause-isolates-on-exit').

Change-Id: Ie56b767cc21e6af3630c742458a6c3e9f7418250
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/155841
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-07-31 21:41:10 +00:00
Zichang Guo 9b6dbd1481 dart run drops wrong argument
With "--enable-experiment" arguments, dartdev drops the wrong argument.

Change-Id: I3cf6b3bc1f21c7c8c33ef8e48236dfcd5a009c3e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156480
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Zichang Guo <zichangguo@google.com>
2020-07-31 01:06:58 +00:00
Zichang Guo ca1279e7e3 Fix DartDev run command failed reading Windows path
On Windows platform, backslashes are used as path separator. (Forward
slashes are also accepted by Windows APIs for most cases) But for an Uri
backslashes will be percent-encoded in the Uri. The other problem is
that "C:\directory" when passed into Uri, the drive letter will be
misinterpreted into scheme (common schemes like "http" or "file").

Bug: https://github.com/dart-lang/sdk/issues/42874
Change-Id: I0fe287b65a5b4faeb791665d2fda9ea0a9744cc4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156363
Commit-Queue: Zichang Guo <zichangguo@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2020-07-30 02:25:10 +00:00
Ben Konyi 8dc4833e86 [ VM/ DDS ] Temporarily disable DDS for beta release
https://github.com/dart-lang/sdk/issues/42727 isn't expected to be fixed
before the next beta release. Disabling DDS temporarily until a proper
fix has been landed.

Change-Id: Ib3233e75a115caa9625f1e96d136b0f6abc5f72e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156343
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-07-30 01:11:51 +00:00
Ben Konyi 45d8bd79f1 [ DartDev ] Launch from snapshot in the current process when possible
Instead of spawning new processes to run a tool for a command, this
change makes it so we run within the current process when possible. In
general, we should avoid spawning any processes when possible from
dartdev unless:

- We need to interact with the child process from dartdev (e.g.,
  analysis server)
- The child needs to interact with the parent process (e.g., DDS)

Change-Id: I9c8cd39de038ab2f3a699165a47bee4c281bda67
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156048
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-07-29 17:28:36 +00:00
pq 2cd8fc1e97 fix command
(Disabled; comment in to enable.)

The command calls out to the DAS using the bulk fix protocol to fix all bulk-fixable issues.

Fixable diagnostics are captured in the `BulkFixProcessor.lintProducerMap`.


Sample output:


```
[~/src/repos/dart/sdk/pkg/dartdev] (fix_cmd) $ dart bin/dartdev.dart fix

*** The `fix` command is provisional and subject to change or removal in future releases. ***

Computing fixes in dartdev...          5.0s
Applying fixes to:
  lib/dummy2.dart
  lib/dummy.dart
Done.
```


Change-Id: I71f82623a452cb747bfc13dba0bb764ec9b1a15b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156046
Reviewed-by: Jaime Wren <jwren@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2020-07-28 22:02:51 +00:00
Ben Konyi c2559967b5 [ DartDev ] Print error to console when trying to launch a missing SDK
artifact (e.g., snapshots)

This should never happen in a stable release unless the SDK installation
is corrupted, but can happen when only building the 'runtime' build
target.

Fixes https://github.com/dart-lang/sdk/issues/42601

Change-Id: I00bd9538984b26350780fc58754169e79e91d24e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156023
Reviewed-by: Jaime Wren <jwren@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2020-07-27 21:34:23 +00:00
Ben Konyi a2fc68c8d2 [ DartDev ] Update CompileNative subcommand help messages to no longer reference dart2native
Fixes https://github.com/dart-lang/sdk/issues/42600

Change-Id: I1e29b0ec1133d13d25f7925a9bd152d671e5a686
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/155243
Reviewed-by: Jaime Wren <jwren@google.com>
2020-07-21 20:50:04 +00:00
Ben Konyi 157ebfe50f Reland "[ VM / DartDev ] Launch DartDev in an isolate within a single main Dart process"
This reverts commit 7e373831ce.

Change-Id: Ib94d793a5753ec6352cd9a65e35f726a63336368
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/154830
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-07-21 16:23:18 +00:00