豆豆友情提示:这是一个非官方 GitHub 代理镜像,主要用于网络测试或访问加速。请勿在此进行登录、注册或处理任何敏感信息。进行这些操作请务必访问官方网站 github.com。 Raw 内容也通过此代理提供。
Skip to content

Commit 8f9c560

Browse files
committed
fix(bazel): unable to set tags for app_bundle rule due to conflict
Fixes that no tags can be specified for `app_bundle` benchmark targets due to a conflict with the debug target and its tags.
1 parent edafc47 commit 8f9c560

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

bazel/benchmark/app_bundling/index.bzl

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,15 @@ def app_bundle(
6565
visibility = visibility,
6666
)
6767

68-
common_esbuild_options = dict(kwargs, **{
68+
common_esbuild_options = {
6969
"config": "%s_esbuild_config" % name,
7070
"entry_point": entry_point,
7171
"target": target,
7272
"platform": platform,
7373
"format": format,
7474
"sourcemap": "external",
7575
"visibility": visibility,
76-
})
76+
}
7777

7878
common_terser_options = {
7979
"visibility": visibility,
@@ -86,14 +86,13 @@ def app_bundle(
8686
esbuild(
8787
name = name,
8888
args = _create_esbuild_minify_options(False),
89-
**common_esbuild_options
89+
**dict(kwargs, **common_esbuild_options)
9090
)
9191

9292
esbuild(
9393
name = "%s.debug" % name,
9494
args = _create_esbuild_minify_options(True),
95-
tags = ["manual"],
96-
**common_esbuild_options
95+
**dict(kwargs, tags = ["manual"], **common_esbuild_options)
9796
)
9897

9998
terser_minified(name = name + ".min", src = name + ".js", **common_terser_options)

bazel/benchmark/app_bundling/test/BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ ng_module(
1515
app_bundle(
1616
name = "bundle",
1717
entry_point = "main_fixture.ts",
18+
tags = ["some-test-tag"],
1819
deps = [":test_fixture_lib"],
1920
)
2021

0 commit comments

Comments
 (0)