diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 39143ed12d..ae83852559 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -10,6 +10,7 @@ * DEPRECATED: `FixNuspec` function is now obsolete, use `FixNuspecs` instead * PERFORMANCE: Improved performance for some edge case - https://github.com/fsprojects/Paket/pull/2299 * BUGFIX: Improved C++ support +* BUGFIX: Treat runtime dependencies as transitive deps - https://github.com/fsprojects/Paket/issues/2334 * BUGFIX: Sort dependencies on obj/references files - https://github.com/fsprojects/Paket/issues/2310 * BUGFIX: Support .NET moniker ">= monoandroid" - https://github.com/fsprojects/Paket/issues/2246 * BUGFIX: Better dependencies file parser errors diff --git a/src/Paket.Core/PaketConfigFiles/LockFile.fs b/src/Paket.Core/PaketConfigFiles/LockFile.fs index 4d7b011810..e87a9f006c 100644 --- a/src/Paket.Core/PaketConfigFiles/LockFile.fs +++ b/src/Paket.Core/PaketConfigFiles/LockFile.fs @@ -649,13 +649,24 @@ type LockFile (fileName:string, groups: Map) = d.Value.Dependencies |> Seq.map (fun (n,_,_) -> n)) |> Set.ofSeq + + let runtimeDeps = + group.Resolution + |> Seq.choose (fun d -> + if d.Value.IsRuntimeDependency then + Some d.Value.Name + else + None) + |> Set.ofSeq let fromSourceFiles = group.RemoteFiles |> Seq.collect (fun d -> d.Dependencies |> Seq.map fst) |> Set.ofSeq - - Set.union fromNuGets fromSourceFiles + + fromSourceFiles + |> Set.union fromNuGets + |> Set.union runtimeDeps match groups.TryFind groupName with | None -> Set.empty