From 202c1c320a358a6b490a2eaf88a188e9656fd223 Mon Sep 17 00:00:00 2001 From: Paul Gschwendtner Date: Fri, 29 Mar 2019 11:48:45 +0100 Subject: [PATCH] build: dgeni bazel target misses runtime fine-grained dep Due to the fact that various targets only depend on their TypeScript source Bazel target, the logic that is reponsible for determining the Bazel managed dependency path is not working because the `nodejs_binary` rule is not able to determine the `NodeModuleInfo` Bazel provider from the TypeScript compilation provider output. See: https://github.com/bazelbuild/rules_nodejs/blob/fe1d1c03630f999c57a63dc3fe1f6ad52ff61c6a/internal/node/node.bzl#L60 Therefore we need to make sure that we don't transitively depend on fine-grained dependencies (such as `@npm//highlight.js`) which *seem* to be transitively brought in by the TypeScript target. This is not correct and prone to unexpected failures (as we experienced on `master) --- tools/dgeni/BUILD.bazel | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/dgeni/BUILD.bazel b/tools/dgeni/BUILD.bazel index 0b514f7851f2..156917815627 100644 --- a/tools/dgeni/BUILD.bazel +++ b/tools/dgeni/BUILD.bazel @@ -20,6 +20,7 @@ ts_library( "@npm//@types/node", "@npm//dgeni", "@npm//dgeni-packages", + "@npm//highlight.js", "//tools/highlight-files:sources", ], tsconfig = ":tsconfig.json",