+
# Assembly Conflict Resolution
## Summary
1. Shared Store
1. Framework directory(s) from higher to lower
1. App directory
-. Additional locations specified in runtimeconfig.dev.json file
+1. Additional locations specified in runtimeconfig.dev.json file
For example, here's the probing order on Windows when running a non-published folder (in order to get additional locations from the app.runtimeconfig.dev.json file)
* `C:\\Program Files (x86)\\coreservicing\\x64`
* `C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackagesFallback`
* `C:\\Program Files\\dotnet\\sdk\\NuGetFallbackFolder`
+Once a deps.json entry has been found in a probe location, no further probes are performed for that entry.
+
#### Deps.json Ordering
The order in which each layer's deps.json is processed is:
* The application
#### Algorithm
1. Determine the probing paths
1. Read the app's deps.json
-1. ->For each package entry, loop through the assemblies
-1. ->->For each assembly, loop through the probing paths
+1. ->For each assembly, loop through the probing paths
+1. ->If the assembly entry has not been found yet:
1. ->->->If the probing path is a framework, then check its deps.json to see if it contains the exact package (by name and version). If so, then use the framework's location
1. ->->->If the probing path is not a framework, then use that location
1. Read the additional deps from --additional-deps and repeat steps 3-6
## Proposed changes for 2.1
Probe the app location before the framework's. This means flip (3) and (4) under **Probe Ordering** above and treat the app as the highest-level framework. The reason is that there may be frameworks that use OOB packages like apps, and we want to have "app wins" in such cases.
-Replace step 5 under **Algorithm** above with:
+Replace step 6 under **Algorithm** above with:
* If the probing path is a framework, and no [minor] or [major] roll-forward occurred on that framework, then check its deps.json to see if it contains the exact package (by name and version). If so, then use the framework's location
* If the probing path is a framework, and a [minor] or [major] roll-forward occurred on that framework, then check its deps.json to see if it contains a newer version of the assembly (by File Version and \ or Assembly Version). If so, then use the framework's location