Currently, the unusedDependencies lint rule, which comes out of the box with spmgraph, simply checks for usages that match a linked product dependency without checking the available targets that come with such product.
For most cases, it works just fine because it's common practice for products to have a single target that matches the product name, i.e.
.library(
name: "FirebaseAuth",
targets: ["FirebaseAuth"]
),
However, for products where either
- The product name doesn't match the target; or
- There are multiple targets available
The linter looks for imports of "$productName", so it wrongly considers it a failure.