NeedsChromeSource: Minor fixes.
The USE flag handling in the controller was not correct.
The build target depgraph was an unnecessarily wide net, only
the sysroot depgraph is needed to check for chrome requirements.
BUG=chromium:1086714
TEST=manually ran endpoint
Change-Id: Ifd6ab36af2e6aa95beba609285826a4ac08506a2
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/chromite/+/2676824
Tested-by: Alex Klein <saklein@chromium.org>
Commit-Queue: Alex Klein <saklein@chromium.org>
Reviewed-by: Michael Mortensen <mmortensen@google.com>
diff --git a/api/controller/packages.py b/api/controller/packages.py
index 5c4b8ce..fe69826 100644
--- a/api/controller/packages.py
+++ b/api/controller/packages.py
@@ -351,7 +351,7 @@
compile_source = input_proto.install_request.flags.compile_source
pkgs = [controller_util.deserialize_package_info(pi) for pi in
input_proto.install_request.packages]
- use_flags = input_proto.install_request.use_flags
+ use_flags = [f.flag for f in input_proto.install_request.use_flags]
result = packages.needs_chrome_source(
build_target,