Skip to content

Commit affaae0

Browse files
author
Kraig Brockschmidt
committed
Revert "Testing image tooltips"
This reverts commit 5d345fd.
1 parent 5d345fd commit affaae0

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

docs/Consume-Packages/Dependency-Resolution.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -87,15 +87,15 @@ NuGet 3.x restores the lowest possible version of a package as defined by its de
8787

8888
For example, in the following figure *1.0-Beta* is considered lower than *1.0* so NuGet chooses the 1.0 version:
8989

90-
![](media/projectJson-dependency-1.png "Choosing the lowest applicable version")
90+
![Choosing the lowest applicable version](media/projectJson-dependency-1.png)
9191

9292
In the next figure, version *2.1* is not available on the feed but because the version constraint is *>= 2.1* NuGet will pick the next lowest version it can find, in this case *2.2*:
9393

94-
![](media/projectJson-dependency-2.png "Choosing the next lowest version available on the feed")
94+
![Choosing the next lowest version available on the feed](media/projectJson-dependency-2.png)
9595

9696
When an application specifies an exact version number, such as *1.2*, that is not available on the feed, NuGet will fail with an error when attempting to install or restore the package:
9797

98-
![](media/projectJson-dependency-3.png "NuGet generates an error when an exact package version is not available")
98+
![NuGet generates an error when an exact package version is not available](media/projectJson-dependency-3.png)
9999

100100
<a name="floating-versions"></a>
101101

@@ -105,7 +105,7 @@ A floating dependency version is specified with the * wildcard, as with *6.0.\**
105105

106106
When a floating version constraint is specified then NuGet will resolve the highest version of a package that matches the version pattern, for example *6.0.** will get the highest version of a package that starts with *6.0*:
107107

108-
![](media/projectJson-dependency-4.png "Choosing version 6.0.1 when a floating version 6.0.* is requested")
108+
![Choosing version 6.0.1 when a floating version 6.0.* is requested](media/projectJson-dependency-4.png)
109109

110110
<a name="nearest-wins"></a>
111111

@@ -115,25 +115,25 @@ When the package graph for an application contains different versions of the sam
115115

116116
In the example below, the application depends directly on Package B with a version constraint of *>=2.0*. The application also depends on Package A which in turn also depends on Package B, but with a *>=1.0* constraint. Because the dependency on Package B *2.0* is nearer to the application in the graph, that version is used:
117117

118-
![](media/projectJson-dependency-5.png "Application using the Nearest Wins rule")
118+
![Application using the Nearest Wins rule](media/projectJson-dependency-5.png)
119119

120120
>[!Warning]
121121
> Applying the Nearest Wins rule can downgrading the package version, thus potentially breaking other dependencies in the graph. This currently produces an error, although we are considering making it a warning instead. See [issue #897 on GitHub](https://github.com/NuGet/Home/issues/897).
122122
123123
This rule also results in greater efficiency with large dependency graph (such as those with the BCL packages) because by once a given dependency is ignored, NuGet also ignores all remaining dependencies on that branch of the graph. In the diagram below, for example, because Package C 2.0 will be used, NuGet can ignore any branches in the graph that refer to an older version of Package C:
124124

125-
![](media/projectJson-dependency-6.png "When NuGet ignores a package in the graph, it ignores that entire branch")
125+
![When NuGet ignores a package in the graph, it ignores that entire branch](media/projectJson-dependency-6.png)
126126

127127
<a name="cousin-dependencies"></a>
128128

129129
#### Cousin dependencies
130130

131131
When different package versions are referred to at the same distance in the graph from the application, NuGet uses the lowest version that satisfies all version requirements (as with the [lowest applicable version](#lowest-applicable-version) and [floating versions](#floating-versions) rules). In the image below, for example, version *2.0* of Package B will satisfy the other *>=1.0* constraint, and will thus be used:
132132

133-
![](media/projectJson-dependency-7.png "Resolving cousin dependencies using the lower version that satisfies all constraints")
133+
![Resolving cousin dependencies using the lower version that satisfies all constraints](media/projectJson-dependency-7.png)
134134

135135
In some cases, it is not possible to meet all version requirements. As shown below, if Package A required exactly Package B *1.0* and Package C requires Package B *>=2.0*, then NuGet cannot resolve the dependencies and will give an error.
136136

137-
![](media/projectJson-dependency-8.png "Unresolvable dependencies due to an exact version requirement")
137+
![Unresolvable dependencies due to an exact version requirement](media/projectJson-dependency-8.png)
138138

139139
In these situations, the top-level consumer (the application or package) should add its own direct dependency on Package B so that the [Nearest Wins](#nearest-wins) rule applies.

0 commit comments

Comments
 (0)