Old RestSharp version in Revit 2025

Old RestSharp version in Revit 2025

SwainStrain
Enthusiast Enthusiast
748 Views
3 Replies
Message 1 of 4

Old RestSharp version in Revit 2025

SwainStrain
Enthusiast
Enthusiast

Hello, 

I am trying to load a specific version of the RestSharp library into Revit 2025, specifically version 106.15.0.0. However, when I run Revit 2025, I notice that a newer version, 108.0.1.0, is being loaded from the Lightbox plugin.

 

SwainStrain_0-1724313955520.png

 

I tried adding a binding redirect to the app.config file to force the loading of the older version, but nothing changed.

 

SwainStrain_1-1724314020346.png

 

Is it possible to force the loadin of the older version? Thank you

0 Likes
Accepted solutions (1)
749 Views
3 Replies
Replies (3)
Message 2 of 4

jeremy_tammik
Alumni
Alumni
Accepted solution

Yes. Luckily for you, starting in Revit 2025, this is possible, cf.:

  

   

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
0 Likes
Message 3 of 4

SwainStrain
Enthusiast
Enthusiast
Thanks Jeremy!
0 Likes
Message 4 of 4

asnow_DSARCSVY7W37
Explorer
Explorer

I just tried out the SDK, when I saw that it is using a version of RestSharp that is compromised I tried installing a version that isn't before delivering code.  I have things compiling with the web.config and project updates:

<configuration>
  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="RestSharp" publicKeyToken="598062e77f915f75" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-112.0.0" newVersion="106.15.0" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>
</configuration>

 

 

And 

<PackageReference Include="RestSharp" Version="106.15.0" />


But, "Could not load file or assembly 'RestSharp, Version=108.0.1.0, Culture=neutral, PublicKeyToken=598062e77f915f75'. The system cannot find the file specified."

If only it was as easy as uninstalling everything forge/RestSharp related, deleting obj/bin/.vs files, recompiling and reinstalling.

Are there plans to update the SDK to stop using RestSharp or at least the constructor they have deleted in the newer version?

 

0 Likes