Closed jagonalez closed 3 months ago
I know you linked to some Gradle code, but I'm not sure how that relates to specifically what we're doing.
The code I linked is for how Gradle reports dependencies when running gradle dependencies
. In Gradle 6 - 7, gradle deprecated configurations: https://docs.gradle.org/current/userguide/declaring_dependencies.html#sec:deprecated-configurations.
If you compare gradle dependencies
vs the fossa-cli output when a gradle project has a deprecated config - we are reporting more dependenices than gradle dependencies
. IMO we should be reporting the same dependencies that gradle does.
Overview
PR adds support for ignoring deprecated configurations in gradle 6-7, which the gradle dependencies task does see here
In gradle 6+, gradle introduced deprecated configurations, however including the configurations at first only induced a warning. In the
gradle dependencies
task, those configurations are ignored when attempting to resolve and list dependencies. This PR changes our gradle script to match what thegradle dependencies
task does.Acceptance criteria
Testing plan
cabal build fossa
cabal run fossa -- analyze ~/dev/fossa-gradle-test -o | jq ".projects[0].graph.deps | length"
gradlew dependencies
Risks
Metrics
Is this change something that can or should be tracked? If so, can we do it today? And how? If its easy, do it
References
Add links to any referenced GitHub issues, Zendesk tickets, Jira tickets, Slack threads, etc.
Example:
Checklist
docs/
.docs/README.ms
and gave consideration to how discoverable or not my documentation is.Changelog.md
. If this PR did not mark a release, I added my changes into an# Unreleased
section at the top..fossa.yml
orfossa-deps.{json.yml}
, I updateddocs/references/files/*.schema.json
AND I have updated example files used byfossa init
command. You may also need to update these if you have added/removed new dependency type (e.g.pip
) or analysis target type (e.g.poetry
).docs/references/subcommands/<subcommand>.md
.