Tooling to validate library `api` dependencies
There doesn't seem to be any tooling to validate that java libraries are exposing the "correct" api dependencies. This is useful to ensure downstream consumers get the proper (compile) classpaths; but would also help during development to expose potential assumptions about the public api.
This would remove a class of bugs similar to https://github.com/deephaven/deephaven-core/issues/4402
Potential similarity with https://github.com/deephaven/deephaven-core/issues/4401
See https://github.com/deephaven/deephaven-core/pull/4403#issuecomment-1699693690 for manual PoC.
https://errorprone.info/ could be useful
https://github.com/autonomousapps/dependency-analysis-gradle-plugin claims to do exactly this!
Dependencies declared on the wrong configuration (api vs implementation vs compileOnly, etc.).