Clone Tools
  • last updated a few minutes ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Render target version only when it differs from requested

    • -3
    • +9
    ./RenderableUnresolvedDependencyResult.java
Collect all rejections during dependency resolution

This commit collects all rejections during dependency resolution,

so that we can properly show them in the dependency insight report.

This highlights some consistency/readability issues, like when a

rejection originates from a constraint. For this reason this commit

does **not** pass tests, and is just the first step towards better

rendering.

    • -0
    • +59
    ./AbstractRenderableDependency.java
    • -15
    • +1
    ./AbstractRenderableDependencyResult.java
    • -0
    • +48
    ./DefaultSection.java
    • -20
    • +1
    ./RenderableUnresolvedDependencyResult.java
    • -27
    • +2
    ./UnresolvableConfigurationResult.java
  1. … 18 more files in changeset.
Collect all rejections during dependency resolution

This commit collects all rejections during dependency resolution,

so that we can properly show them in the dependency insight report.

This highlights some consistency/readability issues, like when a

rejection originates from a constraint. For this reason this commit

does **not** pass tests, and is just the first step towards better

rendering.

    • -0
    • +59
    ./AbstractRenderableDependency.java
    • -15
    • +1
    ./AbstractRenderableDependencyResult.java
    • -0
    • +48
    ./DefaultSection.java
    • -20
    • +1
    ./RenderableUnresolvedDependencyResult.java
    • -27
    • +2
    ./UnresolvableConfigurationResult.java
  1. … 18 more files in changeset.
Consider dependency attributes in insight report

Fixes #5401 by merging configuration attributes and dependency

attributes before comparing against the attributes of the resolved

variant.

  1. … 2 more files in changeset.
Avoid duplicate details in dependencyInsight

Fixes #5397

  1. … 3 more files in changeset.
Make constraints an additional cause instead of replacing requested

This makes it simpler to recognize that a dependency was both requested and constrained.

This commit also reworks the `SelectionReasonHelper` to not use the deprecated `getDescription`

method and implement its own logic instead.

  1. … 3 more files in changeset.
Show that a constraint was used in the dependency insight report

This commit adds a new cause for a component selection reason, `CONSTRAINT`, which is used

whenever a constraint has been used during selection. This lets us recognize, in the resolution

result API, when a constraint has been applied. The dependency insight report makes use of

that information to show a `via constraint` label in that case.

If a dependency constraint also provides a custom reason, then the message displayed in the

report mentions both `via constraint` and the custom reason.

  1. … 5 more files in changeset.
Show variant details in dependency insight report

This commit introduces the visualization of selected variant details in the

dependency insight report. By default, variant details are not displayed,

and it's required to use the `--show-variant-details` flag to enable them.

Depending on the type of dependency, variant details may either refer to

the selected target configuration, or show proper variant attributes. In

both cases, the selected variant display name is shown. When a variant

defines attributes, the attributes of the variant are displayed and compared

to the requested attributes.

The report will show which attributes where matched, which attributes were

compatible, which attributes weren't requested, and eventually which attributes

were found on the variant, but not used during selection.

    • -0
    • +6
    ./AbstractRenderableDependencyResult.java
    • -0
    • +6
    ./RenderableUnresolvedDependencyResult.java
    • -0
    • +11
    ./UnresolvableConfigurationResult.java
  1. … 8 more files in changeset.
Fix code style

Rewrite code to make it less contrived.

Make sure reasons available in published metadata are visible

This commit updates the renderer so that we make sure that dependency

selection reason found in published module metadata is displayed in

the insight report.

Signed-off-by: Cedric Champeau <cedric@gradle.com>

    • -0
    • +29
    ./SelectionReasonHelper.java
  1. … 3 more files in changeset.
Add support for declaring a reason for dependencies

This information is not yet propagated to the dependency insight report,

because for that we need to update `DependencyMetadata` to support reasons

too, which is going to be implemented in a subsequent commit. Instead,

this one just adds the basic structure to be able to declare reasons.

Signed-off-by: Cedric Champeau <cedric@gradle.com>

  1. … 11 more files in changeset.
Make `ModuleComponentSelector` the source of truth for version constraints

This commit pushes `VersionConstraint` as a primary concept in `ModuleComponentSelector`. It replaces the (now)

deprecated `getVersion` call, which didn't reflect all possible constraints on a version. This change has several

consequences:

- version constraints now need to be "serializable"

- version constraints now consist of a preferred version and a list of rejected versions

- only a single item in the rejection list is supported

- Gradle module metadata parsing now generates a prefer/reject list

- Gradle module metadata writing does **not** yet support writing prefer/reject

- the module metadata binary format has been bumped to support prefer/reject in module descriptors

- metadata rules can say `useTarget(VersionConstraint)`

Issue #3312

    • -1
    • +3
    ./AbstractRenderableDependencyResult.java
    • -2
    • +2
    ./RenderableUnresolvedDependencyResult.java
  1. … 91 more files in changeset.
Replace usages of org.gradle.api.Nullable

With javax.annotation.Nullable.

    • -1
    • +2
    ./AbstractRenderableDependencyResult.java
  1. … 460 more files in changeset.
Put the unresolved label on the configuration too

This commit adds the `(u)` label on the configuration in addition to dependencies,

and rephrases the legend for better understanding.

    • -1
    • +1
    ./UnresolvableConfigurationResult.java
  1. … 6 more files in changeset.
Rework the dependency report for unresolvable configurations

This commit changes the way the dependency report works, to avoid creating a copy

of an unresolvable configuration and arbitrary use it to show the dependencies of

the configuration. Instead, we're not adding an additional state, which is

"unresolved", allowing the user to see that this configuration contains unresolved

dependencies.

It's worth mentioning that this commit also fixes a bug in the dependency report

renderer, which used the last configuration renderer to render the legend. As a

consequence, if a configuration had a cyclic dependency but another configuration

rendered after it did not, then the legend wasn't displayed. The code to render

the legend has therefore been moved into its own `LegendRenderer` class.

    • -2
    • +2
    ./RenderableUnresolvedDependencyResult.java
    • -0
    • +101
    ./UnresolvableConfigurationResult.java
  1. … 12 more files in changeset.
Moved `subprojects/diagnostics/src/main/groovy` -> `src/main/java`

    • -0
    • +80
    ./AbstractRenderableDependencyResult.java
    • -0
    • +59
    ./AbstractRenderableModuleResult.java
    • -0
    • +37
    ./DependencyEdge.java
    • -0
    • +60
    ./DependencyReportHeader.java
    • -0
    • +48
    ./InvertedRenderableModuleResult.java
    • -0
    • +27
    ./RenderableDependency.java
    • -0
    • +62
    ./RenderableDependencyResult.java
    • -0
    • +45
    ./RenderableModuleResult.java
    • -0
    • +75
    ./RenderableUnresolvedDependencyResult.java
    • -0
    • +67
    ./RequestedVersion.java
    • -0
    • +63
    ./ResolvedDependencyEdge.java
    • -0
    • +69
    ./UnresolvedDependencyEdge.java
  1. … 137 more files in changeset.