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

Issue 2936333002: WebUI: Replace vulcanize with polymer-bundler (Closed)

Created:
3 years, 6 months ago by dpapad
Modified:
3 years, 5 months ago
Reviewers:
calamity, michaelpg
CC:
chromium-reviews, tsergeant
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

WebUI: Replace vulcanize with polymer-bundler. Summary of changes needed for the migration: - Excluded URLs behavior is different than Vulcanize, need to explicitly list all URLs to be excluded (unlike Vulcanize, transitive deps of an excluded URL are not implicitly excluded). - Excluded URLs need to match exactly, unlike Vulcanize where foo.html would match chrome://some-path/foo.html. - Input HTML files need to have <html><head>...</head><body>...</body></html> tags. - A single invocation of poylmer-bundler produces both "basic" and "lazy" modules (achieved by using the --shell flag), unlike Vulcanize which required two separate invocations. - Using new --manifest-out instead of previous --out-request-list flag to generate depfiles for Ninja. - Using --rewrite-urls-in-templates to preserve previous rewriting behavior. - polymer-bundler does not blow up when it can't find a file (unlike Vulcanize, so check output manifest for any reported "missing" dependencies). - Removed some Windows specific hacks that don't seem necessary anymore. BUG=731881 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation Review-Url: https://codereview.chromium.org/2936333002 Cr-Commit-Position: refs/heads/master@{#488821} Committed: https://chromium.googlesource.com/chromium/src/+/1e6a87f5d3ae459cb14031af36c340349eaff40b

Patch Set 1 #

Patch Set 2 : Add vulcanize_gn.py changes #

Patch Set 3 : Invoke polymer-bundler once, not there yet, but close. #

Patch Set 4 : replace strings on disk #

Patch Set 5 : Remove reference to main module. #

Patch Set 6 : Update depfile generation #

Patch Set 7 : Update to polymer-bundler 2.2.0 #

Patch Set 8 : Fix bookmarks. #

Patch Set 9 : by-vulcanize, by-polymer-bundler #

Patch Set 10 : Update NPM dependencies. #

Patch Set 11 : Remove strings.js #

Patch Set 12 : Fix wrong return. #

Patch Set 13 : update polymer bundler #

Total comments: 12

Patch Set 14 : Address comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+205 lines, -190 lines) Patch
M chrome/browser/resources/md_bookmarks/BUILD.gn View 1 2 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/resources/md_bookmarks/bookmarks.html View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/md_downloads/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/resources/md_history/BUILD.gn View 1 2 2 chunks +11 lines, -19 lines 0 comments Download
M chrome/browser/resources/md_history/lazy_load.html View 1 2 1 chunk +12 lines, -7 lines 0 comments Download
M chrome/browser/resources/settings/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +11 lines, -18 lines 0 comments Download
M chrome/browser/resources/settings/i18n_setup.html View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/lazy_load.html View 1 2 1 chunk +18 lines, -13 lines 0 comments Download
M chrome/browser/resources/vulcanize.gni View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +13 lines, -11 lines 0 comments Download
M chrome/browser/resources/vulcanize_gn.py View 1 2 3 4 5 6 7 8 9 10 11 12 13 6 chunks +107 lines, -92 lines 0 comments Download
M chrome/test/data/webui/polymer_browser_test_base.js View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -1 line 0 comments Download
M docs/optimizing_web_uis.md View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M third_party/node/README.chromium View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
A third_party/node/chromium_polymer_bundler.patch View 1 1 chunk +13 lines, -0 lines 0 comments Download
D third_party/node/chromium_vulcanize.patch View 1 chunk +0 lines, -12 lines 0 comments Download
M third_party/node/node_modules.py View 1 2 3 4 5 6 1 chunk +3 lines, -2 lines 0 comments Download
M third_party/node/node_modules.tar.gz.sha1 View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M third_party/node/package.json View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/node/update_npm_deps View 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 71 (58 generated)
dpapad
Note to self: Also update https://cs.chromium.org/chromium/src/docs/optimizing_web_uis.md?type=cs&q=polymer-bundler&sq=package:chromium&l=30
3 years, 6 months ago (2017-06-15 00:08:33 UTC) #3
dpapad
I believe this is ready for review now. I have manually done sanity checking on ...
3 years, 5 months ago (2017-07-19 01:29:43 UTC) #48
calamity
Nice! This mostly looks good. I'm not super familiar with polymer bundler, so all I ...
3 years, 5 months ago (2017-07-19 06:15:33 UTC) #49
michaelpg
On 2017/06/15 00:08:33, dpapad wrote: > Note to self: Also update > https://cs.chromium.org/chromium/src/docs/optimizing_web_uis.md?type=cs&q=polymer-bundler&sq=package:chromium&l=30 this
3 years, 5 months ago (2017-07-19 18:51:01 UTC) #50
michaelpg
looking good https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/vulcanize_gn.py File chrome/browser/resources/vulcanize_gn.py (right): https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/vulcanize_gn.py#newcode13 chrome/browser/resources/vulcanize_gn.py:13: import json nit: alphabetical https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/vulcanize_gn.py#newcode199 chrome/browser/resources/vulcanize_gn.py:199: shutil.rmtree(tmp_out_dir) ...
3 years, 5 months ago (2017-07-19 18:52:00 UTC) #51
dpapad
https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/md_history/BUILD.gn File chrome/browser/resources/md_history/BUILD.gn (right): https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/md_history/BUILD.gn#newcode31 chrome/browser/resources/md_history/BUILD.gn:31: polymer_css_build("build") { On 2017/07/19 at 06:15:33, calamity wrote: > ...
3 years, 5 months ago (2017-07-19 20:49:39 UTC) #52
dpapad
On 2017/07/19 at 18:51:01, michaelpg wrote: > On 2017/06/15 00:08:33, dpapad wrote: > > Note ...
3 years, 5 months ago (2017-07-19 20:49:51 UTC) #53
calamity
lgtm
3 years, 5 months ago (2017-07-20 02:55:50 UTC) #59
michaelpg
lgtm https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/vulcanize_gn.py File chrome/browser/resources/vulcanize_gn.py (right): https://codereview.chromium.org/2936333002/diff/300001/chrome/browser/resources/vulcanize_gn.py#newcode199 chrome/browser/resources/vulcanize_gn.py:199: shutil.rmtree(tmp_out_dir) On 2017/07/19 20:49:38, dpapad wrote: > On ...
3 years, 5 months ago (2017-07-21 00:57:12 UTC) #60
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2936333002/320001
3 years, 5 months ago (2017-07-21 20:24:17 UTC) #64
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/506935)
3 years, 5 months ago (2017-07-21 21:28:38 UTC) #66
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2936333002/320001
3 years, 5 months ago (2017-07-22 00:14:30 UTC) #68
commit-bot: I haz the power
3 years, 5 months ago (2017-07-22 00:22:42 UTC) #71
Message was sent while issue was closed.
Committed patchset #14 (id:320001) as
https://chromium.googlesource.com/chromium/src/+/1e6a87f5d3ae459cb14031af36c3...

Powered by Google App Engine
This is Rietveld 408576698