Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(197)

Side by Side Diff: tools/gardening/lib/src/client.dart

Issue 2996503002: Small improvements to bot summary. (Closed)
Patch Set: Remove spurious 'print'. Created 3 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tools/gardening/bin/summary.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import 'dart:async'; 5 import 'dart:async';
6 import 'dart:io' hide HttpException; 6 import 'dart:io' hide HttpException;
7 7
8 import 'buildbot_data.dart'; 8 import 'buildbot_data.dart';
9 import 'buildbot_loading.dart'; 9 import 'buildbot_loading.dart';
10 import 'buildbot_structures.dart'; 10 import 'buildbot_structures.dart';
(...skipping 12 matching lines...) Expand all
23 } 23 }
24 24
25 /// Buildbot client that pulls build bot results through http. 25 /// Buildbot client that pulls build bot results through http.
26 class HttpBuildbotClient implements BuildbotClient { 26 class HttpBuildbotClient implements BuildbotClient {
27 final HttpClient _client = new HttpClient(); 27 final HttpClient _client = new HttpClient();
28 28
29 @override 29 @override
30 Future<BuildResult> readResult(BuildUri buildUri) async { 30 Future<BuildResult> readResult(BuildUri buildUri) async {
31 try { 31 try {
32 return await readBuildResultFromHttp(_client, buildUri); 32 return await readBuildResultFromHttp(_client, buildUri);
33 } on HttpException { 33 } on HttpException catch (e) {
34 return null;
35 } on SocketException catch (e) {
34 return null; 36 return null;
35 } 37 }
36 } 38 }
37 39
38 int get mostRecentBuildNumber => -2; 40 int get mostRecentBuildNumber => -2;
39 41
40 @override 42 @override
41 void close() { 43 void close() {
42 _client.close(); 44 _client.close();
43 } 45 }
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 buildUri = buildUri.withBuildNumber(buildNumber); 89 buildUri = buildUri.withBuildNumber(buildNumber);
88 } 90 }
89 } 91 }
90 } 92 }
91 93
92 @override 94 @override
93 void close() { 95 void close() {
94 // Nothing to do. 96 // Nothing to do.
95 } 97 }
96 } 98 }
OLDNEW
« no previous file with comments | « tools/gardening/bin/summary.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698