foursquare/twitter-commons — pull request #10 by foursquare-markcc (2012-12-04 15:26:38+00:00)
Title: Update dependency checking for instransitive deps.

Before this change, the dependency checking code only generated errors
in cases where, without chunking, compilation would fail.

For example, if the following targets and deps were declared:

scala_library(name="A", ..., deps=[pants("B")])
scala_library(name="B", ..., deps=[pants("C")])
scala_library(name="C", ...)

If the source files in target A actually referenced members of C,
the compilation would not fail, and no dependency checking error message
would be generated. But if A explicitly references members of C, it
should declare that dependency.

This change adds a dependency checking flag, "intransitive-deps", which
can be set to either "none", "warn", or "error".

If the flag is set to "none" (the default), then the dependency checker will
not generate errors for intransitive dependencies.

If the flag is set to "warn", then the dependency checker will
print error messages for intransitive deps, but will cause the build
to fail, and will not populate the build products with the errors.

If the flag is set to "error", then it will print out error messages
for intransitive deps, populate the build products with information
about the deps, and will cause the build to fail with an error.