Using mimekit nuget package (via paket) in common project removes existing System.net.http.dll from other projects referencing common project RRS feed

  • Question

  • I had added a new reference of mimekit library (added mimekit and mailkit via paket) in common project used by several other projects.

    To use mimekit I used below code:

    using MimeKit;
    namespace Project.Common.Email.Interfaces
        public interface IMailKitBody
            BodyBuilder BodyBuilder { get; set; }

    But while building the complete solution, System.net.http.dll is getting removed from one of the dependent projects having reference of common project and another project which actually have a reference of System.net.http.dll.

    And as soon as I remove this file from Common then System.net.http.dll starts appearing in the dependent project.

    I know Mimekit is dependent upon System.net.http.dll and it could conflict with existing one in dependent projects.
    I have already tried following things:
    -removing System.net.http.dll reference from common
    -Setting Copy Local property of DLL to True 
    -Adding reference System.net.http.dll from package folder

    Could anyone help me out how this problem be resolved?
    Thursday, May 2, 2019 11:50 AM