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

Side by Side Diff: third_party/WebKit/Tools/Scripts/webkitpy/w3c/wpt_manifest.py

Issue 2848353002: Add WPTManifest log line to diagnose slow manifest generation (Closed)
Patch Set: Add two more log lines in the main function Created 3 years, 7 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 | « third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py ('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 2017 The Chromium Authors. All rights reserved. 1 # Copyright 2017 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """WPTManifest is responsible for handling MANIFEST.json. 5 """WPTManifest is responsible for handling MANIFEST.json.
6 6
7 The MANIFEST.json file contains metadata about files in web-platform-tests, 7 The MANIFEST.json file contains metadata about files in web-platform-tests,
8 such as what tests exist, and extra information about each test, including 8 such as what tests exist, and extra information about each test, including
9 test type, options, URLs to use, and reference file paths if applicable. 9 test type, options, URLs to use, and reference file paths if applicable.
10 """ 10 """
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 _log.error('Manifest base not found at "%s".', base_manifest_path) 98 _log.error('Manifest base not found at "%s".', base_manifest_path)
99 host.filesystem.write_text_file(base_manifest_path, '{}') 99 host.filesystem.write_text_file(base_manifest_path, '{}')
100 100
101 if not host.filesystem.exists(manifest_path): 101 if not host.filesystem.exists(manifest_path):
102 _log.debug('Manifest not found, copying from base "%s".', base_manif est_path) 102 _log.debug('Manifest not found, copying from base "%s".', base_manif est_path)
103 host.filesystem.copyfile(base_manifest_path, manifest_path) 103 host.filesystem.copyfile(base_manifest_path, manifest_path)
104 104
105 wpt_path = manifest_path = finder.path_from_layout_tests('external', 'wp t') 105 wpt_path = manifest_path = finder.path_from_layout_tests('external', 'wp t')
106 WPTManifest.generate_manifest(host, wpt_path) 106 WPTManifest.generate_manifest(host, wpt_path)
107 107
108 # Adding this log line to diagnose https://crbug.com/714503
109 _log.debug('Manifest generation completed.')
110
108 @staticmethod 111 @staticmethod
109 def generate_manifest(host, dest_path): 112 def generate_manifest(host, dest_path):
110 """Generates MANIFEST.json on the specified directory.""" 113 """Generates MANIFEST.json on the specified directory."""
111 executive = host.executive 114 executive = host.executive
112 finder = WebKitFinder(host.filesystem) 115 finder = WebKitFinder(host.filesystem)
113 manifest_exec_path = finder.path_from_tools_scripts('webkitpy', 'thirdpa rty', 'wpt', 'wpt', 'manifest') 116 manifest_exec_path = finder.path_from_tools_scripts('webkitpy', 'thirdpa rty', 'wpt', 'wpt', 'manifest')
114 117
115 cmd = ['python', manifest_exec_path, '--work', '--tests-root', dest_path ] 118 cmd = ['python', manifest_exec_path, '--work', '--tests-root', dest_path ]
116 _log.debug('Running command: %s', ' '.join(cmd)) 119 _log.debug('Running command: %s', ' '.join(cmd))
117 proc = executive.popen(cmd, stdout=executive.PIPE, stderr=executive.PIPE , stdin=executive.PIPE, cwd=finder.webkit_base()) 120 proc = executive.popen(cmd, stdout=executive.PIPE, stderr=executive.PIPE , stdin=executive.PIPE, cwd=finder.webkit_base())
118 out, err = proc.communicate('') 121 out, err = proc.communicate('')
119 if proc.returncode: 122 if proc.returncode:
120 _log.info('# ret> %d', proc.returncode) 123 _log.info('# ret> %d', proc.returncode)
121 if out: 124 if out:
122 _log.info(out) 125 _log.info(out)
123 if err: 126 if err:
124 _log.info(err) 127 _log.info(err)
125 host.exit(proc.returncode) 128 host.exit(proc.returncode)
126 return proc.returncode, out 129 return proc.returncode, out
OLDNEW
« no previous file with comments | « third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698