Skip to content

Commit 6317ea9

Browse files
moruowaitmarkusdap
authored andcommitted
fix incompatible_depset_union flag (#106)
1 parent 4012fc5 commit 6317ea9

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

jsonnet/jsonnet.bzl

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -220,13 +220,11 @@ def _jsonnet_to_json_impl(ctx):
220220
outputs += [compiled_json]
221221
command += [ctx.file.src.path, "-o", compiled_json.path]
222222

223-
transitive_data = []
224-
for dep in ctx.attr.deps:
225-
# NB(sparkprime): (1) transitive_data is never used, since runfiles is only
226-
# used when .files is pulled from it. (2) This makes sense - jsonnet does
227-
# not need transitive dependencies to be passed on the commandline. It
228-
# needs the -J but that is handled separately.
229-
transitive_data += dep.data_runfiles.files.to_list()
223+
transitive_data = depset(transitive = [dep.data_runfiles.files for dep in ctx.attr.deps])
224+
# NB(sparkprime): (1) transitive_data is never used, since runfiles is only
225+
# used when .files is pulled from it. (2) This makes sense - jsonnet does
226+
# not need transitive dependencies to be passed on the commandline. It
227+
# needs the -J but that is handled separately.
230228

231229
files = jsonnet_ext_str_files + jsonnet_ext_code_files
232230

0 commit comments

Comments
 (0)