PUN Classic assembly conflict errors for UWP build specifically Hololens 2

Hello

I am working on a project that is being developed on Unity 2018.4.29f1 with Mapbox SDK which is currently compatible with .net scripting backend only and therefore we are using .net scripting backend paired up with PUN 2. (Tried PUN Classic as well)

I am well aware that the unity has ended support for .net scripting backend and have been removed in latest unity version and Photon also advises not to use PUN Classic in new projects but it is the need of the project.

Configuration:

  1. Unity 2018.4.29f1
  2. PUN 2 (v2.40)
  3. Scripting backend: .Net
  4. API compatibility level: .Net 4x

Problem:

The problem we are facing for about a week now is that unity builds the visual studio solution fine for UWP but when we try to build it for Hololens 2 from visual studio 2017 version 15.9.45 we get photon assembly conflict with .nuget packages.

Errors:

1> Failed to fix references for field System.Threading.Tasks.Task ExitGames.Client.Photon.PhotonMessageWebSocket::sendTask

1> Failed to fix references for type ExitGames.Client.Photon.PhotonMessageWebSocket

Output Build Log: (wouldn't let direct uploading)

https://drive.google.com/file/d/1mXSeO_OI2z8EoxaYb0R3TtcVY4ANTz5l/view?usp=sharing

Solutions I tried:

  1. Tried creating app.config with redirect bindings and side by side assembly loading later to realize that UWP doesn't support app.config. There are some work arounds as well that didn't seem to work for me.
  2. Tried passing the conflicting assemblies in project.json so .nuget may download at the time of build.
  3. Tried adding reference in visual studio but that didn't seem to work.

What I am looking for:

Some way to load these assemblies side by side or implement redirect bindings for UWP or any solution that would work.