rules_jsonnet icon indicating copy to clipboard operation
rules_jsonnet copied to clipboard

Strict mode for multiple_outputs

Open bshi opened this issue 6 years ago • 3 comments

It would be helpful for the jsonnet_to_json rule to have an argument triggering verification that the outs enumerated in the rule matches all the output files generated from the inputs.

I was recently bit by a case where I added several output files but forgot to update my BUILD rule.

bshi avatar Apr 02 '18 18:04 bshi

good idea

sparkprime avatar Apr 21 '18 15:04 sparkprime

Just hit this as well. It is massively confusing to see:

INFO: From Compiling Jsonnet to JSON for config:
bazel-out/k8-fastbuild/bin/bare/bb-browser.json
bazel-out/k8-fastbuild/bin/bare/bb-event-service.json
bazel-out/k8-fastbuild/bin/bare/bb-runner.json
bazel-out/k8-fastbuild/bin/bare/bb-scheduler.json
bazel-out/k8-fastbuild/bin/bare/bb-storage.json
bazel-out/k8-fastbuild/bin/bare/bb-worker.json

but actually some files not being there without any error.

mickael-carl avatar Jun 24 '19 14:06 mickael-carl

stdout from jsonnet is the list of file names, which should make this pretty easy.

sparkprime avatar Jun 24 '19 14:06 sparkprime