Ryan Macnak
a4f3b53fe8
Reapply "Partial static mode changes for vm-service and tests (part 3)."
...
Remove use of castTo, which is not yet available in the prebuilt SDK used to build Observatory.
Bug: https://github.com/dart-lang/sdk/issues/31587
Change-Id: Ia118710a2c4dca1851935d284e1a78a9c6517256
Reviewed-on: https://dart-review.googlesource.com/34022
Reviewed-by: Siva Annamalai <asiva@google.com >
Commit-Queue: Ryan Macnak <rmacnak@google.com >
2018-01-11 01:31:17 +00:00
Jens Johansen
37c28f8661
Revert "Reapply "Partial static mode changes for vm-service and tests (part 3).""
...
This reverts commit c9f6e8695d .
Reason for revert: Change brakes Observatory:
```
$ out/ReleaseX64/dart --observe hello.dart
Observatory listening on http://127.0.0.1:8181/
Hello, world!
vm-service: isolate(348927110) 'hello.dart:main()' has no debugger attached and is paused at exit. Connect to Observatory at http://127.0.0.1:8181/ to debug.
```
Going to the website I get
```
Unexpected exception:
NoSuchMethodError: method not found: 'castTo'
Receiver: ""
Arguments: [Instance of 'it']
StackTrace:
main.dart.js 2017:3 Object.f
main.dart.js 2203:30 Object.qn
main.dart.js 21316:11 b3.aQ
main.dart.js 20634:6 b3.c2
main.dart.js 20643:8 TZ.$1
main.dart.js 36992:29 UB.$0
main.dart.js 36982:9 Ux.nq
main.dart.js 36990:30 UC.$1
main.dart.js 36992:29 UB.$0
main.dart.js 36982:9 Ux.nq
===== asynchronous gap ===========================
main.dart.js 4840:12 Zh.e4
main.dart.js 3930:17 L.lK
main.dart.js 3932:28 L.ad
main.dart.js 20621:12 b3.dart.ba.lE
main.dart.js 20621:112 b3.dart.ba.lE
main.dart.js 20603:22 b3.cD
===== asynchronous gap ===========================
main.dart.js 4840:12 Zh.e4
main.dart.js 3930:17 L.lK
main.dart.js 3932:28 L.ad
main.dart.js 20621:12 ms.dart.ba.lE
main.dart.js 20621:112 ms.dart.ba.lE
main.dart.js 15829:10 Y4.bs
```
and Observatory is completely broken.
From https://github.com/dart-lang/sdk/issues/31397 it seems that Observatory uses an "old" sdk, i.e. we cannot use new stuff as castTo.
Original change's description:
> Reapply "Partial static mode changes for vm-service and tests (part 3)."
>
> Fix dynamic mode static warnings.
>
> Bug: https://github.com/dart-lang/sdk/issues/31587
> Change-Id: I966349f5409f911efacd11f08ffd469373bcd434
> Reviewed-on: https://dart-review.googlesource.com/33540
> Commit-Queue: Ryan Macnak <rmacnak@google.com >
> Reviewed-by: Siva Annamalai <asiva@google.com >
TBR=rmacnak@google.com ,asiva@google.com
Change-Id: I775544cb5ab212cc836bc63181bdce31d19380b8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/31587
Reviewed-on: https://dart-review.googlesource.com/33800
Commit-Queue: Jens Johansen <jensj@google.com >
Reviewed-by: Jens Johansen <jensj@google.com >
2018-01-10 12:21:53 +00:00
Ryan Macnak
c9f6e8695d
Reapply "Partial static mode changes for vm-service and tests (part 3)."
...
Fix dynamic mode static warnings.
Bug: https://github.com/dart-lang/sdk/issues/31587
Change-Id: I966349f5409f911efacd11f08ffd469373bcd434
Reviewed-on: https://dart-review.googlesource.com/33540
Commit-Queue: Ryan Macnak <rmacnak@google.com >
Reviewed-by: Siva Annamalai <asiva@google.com >
2018-01-10 01:28:39 +00:00
Ryan Macnak
e8d9d945f3
Revert "Partial static mode changes for vm-service and tests (part 3)."
...
This reverts commit 6ccd7b8ac2 .
Reason for revert: analyzer failures
Original change's description:
> Partial static mode changes for vm-service and tests (part 3).
>
> Bug: https://github.com/dart-lang/sdk/issues/31587
> Change-Id: I812fd4cd8e74875ce7ada9886035137af2fef73a
> Reviewed-on: https://dart-review.googlesource.com/33100
> Reviewed-by: Siva Annamalai <asiva@google.com >
TBR=rmacnak@google.com ,asiva@google.com
Change-Id: Ic368fc23f58e02cafbaf6ae81dbcbffc3dcced13
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/31587
Reviewed-on: https://dart-review.googlesource.com/33240
Reviewed-by: Ryan Macnak <rmacnak@google.com >
Commit-Queue: Ryan Macnak <rmacnak@google.com >
2018-01-09 02:37:56 +00:00
Ryan Macnak
6ccd7b8ac2
Partial static mode changes for vm-service and tests (part 3).
...
Bug: https://github.com/dart-lang/sdk/issues/31587
Change-Id: I812fd4cd8e74875ce7ada9886035137af2fef73a
Reviewed-on: https://dart-review.googlesource.com/33100
Reviewed-by: Siva Annamalai <asiva@google.com >
2018-01-09 01:40:10 +00:00
Peter von der Ahé
e8aef37eac
Clean up patches so they can be compiled by Fasta.
...
Change-Id: Ie436375c78496366accf0ba82938e54cbe30b143
Reviewed-on: https://dart-review.googlesource.com/3001
Commit-Queue: Peter von der Ahé <ahe@google.com >
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com >
Reviewed-by: Vyacheslav Egorov <vegorov@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
2017-10-05 14:05:50 +00:00
Jacob Richman
4360e99d18
Revert "Fix observatory tests broken by running dartfmt."
...
This reverts commit b1f7e6d94673b098c93c187fe3efc45c15f27edc.
BUG=
Committed: https://github.com/dart-lang/sdk/commit/62be0eacfbb36bdc92a05c7c35bb4506621b6a3a
Review-Url: https://codereview.chromium.org/2767533002 .
2017-03-21 10:07:26 -07:00
Jacob Richman
62be0eacfb
Revert "Fix observatory tests broken by running dartfmt."
...
This reverts commit b1f7e6d94673b098c93c187fe3efc45c15f27edc.
BUG=
Review-Url: https://codereview.chromium.org/2767533002 .
2017-03-20 22:19:22 -07:00
Jacob Richman
88f8aacd5f
Re-apply rolled back CL to apply dartfmt to runtime.
...
Fix observatory tests broken by running dartfmt due to line and column changes.
Temporarily reverted formatting for evaluate_activation_test.dart as dartfmt doesn't yet handle multitests.
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2759973004 .
2017-03-20 21:44:59 -07:00
Ryan Macnak
ea4744a06f
Revert "Run dartfmt on all files under runtime."
...
This reverts commit 15f393f189 .
The change caused many service test failures due to changed line numbers.
TBR=jacobr@google.com
Review-Url: https://codereview.chromium.org/2762583003 .
2017-03-20 13:42:55 -07:00
Jacob Richman
15f393f189
Run dartfmt on all files under runtime.
...
I've omitted files where the formatter output is significantly uglier
than the original code and I'll send those files in a separate CL
with options for how to make the code look reasonable while still
taking advantage of the formatter.
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2751423005 .
2017-03-20 13:13:50 -07:00
Peter von der Ahé
ab45caba0f
Fix errors in VM patch files.
...
R=vegorov@google.com
Review-Url: https://codereview.chromium.org/2717573003 .
2017-02-27 08:55:17 +01:00
Peter von der Ahé
00bed94e0c
Fix various nits in VM patch files.
...
R=vegorov@google.com
Review-Url: https://codereview.chromium.org/2705593002 .
2017-02-17 16:28:57 +01:00
John McCutchan
6bf86eacd7
Add getIsolateID to Service class in dart:developer
...
Fixes https://github.com/dart-lang/sdk/issues/23924
BUG=
R=asiva@google.com
Review URL: https://codereview.chromium.org/2542003002 .
2016-12-01 12:48:49 -08:00
John McCutchan
63e4f69e5e
Provide an API to dart:developer to control the web server hosting the Service Protocol
...
- [x] Add `ServiceProtocolnfo` class to dart:developer.
- [x] Add `Service` class to dart:developer.
- [x] Add `Service.getInfo` static method to dart:developer.
- [x] Add `Service.controlWebServer` static method to dart:developer.
API:
```dart
/// Information about the service protocol.
class ServiceProtocolInfo {
/// The major version of the protocol.
final int majorVersion;
/// The minor version of the protocol.
final int minorVersion;
/// The Uri to access the service. If the web server is not running, this
/// will be null.
final Uri serverUri;
}
/// Access information about the service protocol and control the web server.
class Service {
/// Get information about the service protocol.
static Future<ServiceProtocolInfo> getInfo();
/// Control the web server that the service protocol is accessed through.
static Future<ServiceProtocolInfo> controlWebServer({bool enable: false});
}
```
... and add a randomly generated authentication token path prefix that must be passed in to access the service protocol.
Old base url:
Observatory listening on http://127.0.0.1:54804/
New base url:
Observatory listening on http://127.0.0.1:54804/ <token>/
For example:
Observatory listening on http://127.0.0.1:54804/PTwjm8Ii8qg=/
Many tools will need to be updated.
Fixes #23320
BUG=
R=asiva@google.com , rmacnak@google.com
Review URL: https://codereview.chromium.org/2438613002 .
2016-10-31 12:32:23 -07:00
Vyacheslav Egorov
eb8c24e133
Reland "Merge more Kernel infrastructure from kernel_sdk SDK fork."
...
R=zra@google.com
BUG=
Review URL: https://codereview.chromium.org/2451623006 .
2016-10-27 10:09:22 +02:00
Vyacheslav Egorov
12968edb9c
Revert "Reland "Merge more Kernel infrastructure from kernel_sdk SDK fork.""
...
This reverts commit 4e7a31262e .
Windows bots are broken now.
R=zra@google.com
BUG=
Review URL: https://codereview.chromium.org/2451893004 .
2016-10-26 17:07:18 +02:00
Vyacheslav Egorov
4e7a31262e
Reland "Merge more Kernel infrastructure from kernel_sdk SDK fork."
...
This relands commit 2fed1c3905 with fixes to ensure that analyzer summaries are correctly created and XARM build does not try to use target binaries on the host.
R=zra@google.com
BUG=
Review URL: https://codereview.chromium.org/2453773002 .
2016-10-26 16:48:28 +02:00
Vyacheslav Egorov
cf7ff42e60
Revert "Merge more Kernel infrastructure from kernel_sdk SDK fork."
...
This reverts commit 2fed1c3905 .
SDK builds are failing
TBR=zra@google.com
Review URL: https://codereview.chromium.org/2455593002 .
2016-10-26 13:06:27 +02:00
Vyacheslav Egorov
2fed1c3905
Merge more Kernel infrastructure from kernel_sdk SDK fork.
...
- bring patched SDK generation scripts and VM patch tweaks that allow VM patch files to be parsed by analyzer front-end;
Patched SDK is an SDK with all VM patches spliced into it. Kernel compiler is based on the analyzer front-end which does
not have any patch files support/model so for it to produce Kernel files that match VM we need to generate a such patched SDKs.
- bring test script modifications that allow to test Kernel pipeline
BUG=
R=asiva@google.com , kmillikin@google.com , whesse@google.com , zra@google.com
Review URL: https://codereview.chromium.org/2434123003 .
2016-10-26 13:02:54 +02:00
Matthias Hausner
e11ca24053
Use metadata annotation @patch for patch classes
...
Annotate patch classes and top-level patch functions with @patch
instead of the pseudo-keyword patch. This allows the analyzer
to read patch files, and matches the syntax that dart2js uses.
The deprecated syntax is still supported, but a warning is printed when detected.
BUG=
Review URL: https://codereview.chromium.org/2220883004 .
2016-08-09 09:48:03 -07:00
Todd Turnidge
2ef7f6f140
Improve --trace-service to help track down problems in full_coverage_test.
...
BUG=
R=johnmccutchan@google.com
Review URL: https://codereview.chromium.org/1690263003 .
2016-02-12 13:26:16 -08:00
John McCutchan
89c49b9e87
Add dart:developer.postEvent for posting events to the service protocol from Dart code
...
- Add dart:developer.postEvent for posting events to the service protocol.
- Add 'Extension' service protocol event stream.
- Unit test.
- Update service.md
- Bug fix for logging stream.
R=turnidge@google.com
Review URL: https://codereview.chromium.org/1537523002 .
2015-12-17 09:34:52 -08:00
John McCutchan
a1ed9c6d17
Remove public dart:isolate dependency from dart:developer
...
- Move code from sdk/lib into runtime/lib.
- Remove dependency on dart:isolate from dart:developer.
R=rmacnak@google.com
Review URL: https://codereview.chromium.org/1522203002 .
2015-12-14 13:26:05 -08:00
John McCutchan
7052bd6bed
Rework service extensions to be safe
...
- When scheduling a service extension to be invoked, store the closure in an array held in the isolate.
- At the tail of IsolateMessageHandler::HandleMessage, invoke all pending service extension closures.
R=iposva@google.com , turnidge@google.com
Review URL: https://codereview.chromium.org//1299493007 .
2015-08-27 11:23:39 -07:00
Seth Ladd
26eaf632cf
removes a return from a void function
...
BUG=
Review URL: https://codereview.chromium.org//1305583003 .
2015-08-20 13:40:29 -07:00
Ryan Macnak
360b40a599
Update return type of dart2js patch of dart:developer.log.
...
Review URL: https://codereview.chromium.org//1302823002 .
2015-08-19 13:42:53 -07:00
John McCutchan
4505a79e58
Increment next sequence number
...
BUG=
Review URL: https://codereview.chromium.org//1260343004 .
2015-08-04 07:59:13 -07:00
John McCutchan
a2757141b0
Make dart:developer log more user friendly
...
- Make required arguments required.
- Validate required arguments in Dart before calling native.
- timestamp is now a DateTime.
- level has a default (ALL).
- sequence number is last + 1 if not provided.
R=lrn@google.com
Review URL: https://codereview.chromium.org//1266053003 .
2015-08-04 07:12:39 -07:00
John McCutchan
7640cf4b85
Fix test failure
...
patch from issue 1271693003 at patchset 20001 (http://crrev.com/1271693003#ps20001 )
Review URL: https://codereview.chromium.org//1270953003 .
2015-08-04 07:05:34 -07:00
William Hesse
bdda0eff52
Revert "Change msg to message in debugger function."
...
This reverts commit 2ae214316c .
BUG=
Review URL: https://codereview.chromium.org//1261203005 .
2015-08-04 15:22:47 +02:00
Lasse R.H. Nielsen
2ae214316c
Change msg to message in debugger function.
...
BUG=23949
R=johnmccutchan@google.com
Review URL: https://codereview.chromium.org//1271693003 .
2015-08-04 14:58:13 +02:00
John McCutchan
bfd2d4ed2a
Refactor dart:developer log to use named parameters
...
BUG=
R=rmacnak@google.com
Review URL: https://codereview.chromium.org//1247803002 .
2015-07-21 10:01:37 -07:00
John McCutchan
f818f9dc0f
Support piping log data over the service protocol
...
BUG=
R=rmacnak@google.com
Review URL: https://codereview.chromium.org//1241683005 .
2015-07-21 07:54:46 -07:00
rmacnak@google.com
016214f002
Add Debugger.inspect. 1976 here we come!
...
R=johnmccutchan@google.com
Review URL: https://codereview.chromium.org//1132153002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@45664 260f80e4-7a28-3924-810f-c04153c831b5
2015-05-08 22:18:43 +00:00
johnmccutchan@google.com
1f851efdbb
Rename 'dart:debugger' to 'dart:developer'
...
- Rename 'dart:debugger' to 'dart:developer'
- Make 'breakHere' and 'breakHereIf' top level functions.
R=iposva@google.com
Review URL: https://codereview.chromium.org//1132113002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@45658 260f80e4-7a28-3924-810f-c04153c831b5
2015-05-08 21:24:57 +00:00