Could not load type 'RestSharp.RestClientOptions' from assembly 'RestSharp, Version=106.4.2.0, Culture=neutral, PublicKeyToken=598062e77f915f75'.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
2 years ago
How do you handle conflicts in versions of common libraries used by plugins ?

I have a plugin that uses RestSharp and it has a later version to that in current plugins which copy in the .dll to bin directory

Send in Blue has version 106.4.2.0 in the directory
Easypost references EasyPost-Official which references  Restsharp 106.4.2.0
There version that ends up in the \Plugins\Bin folder is 106.4.2.0

Which of course conflicts with the version I am using in the new plugin resulting in the above error

I guess I wonder why in the latest release v4.50.1 an older version of RestSharp is still being used

Is it possible to have different versions of the same library used in different plugins ?
2 years ago
Nope, unfortunately, this issue is still open. We cannot use different versions of the same library in different plugins. And that's why we are using not the latest RestSharp in our plugins since this version (106.4.2) is used in dependency of EasyPost package.
2 years ago
I'm not sure if this helps, but you may be able to
"...redirect your app to use a different version of an assembly in a number of ways"

https://docs.microsoft.com/en-us/dotnet/framework/configure-apps/redirect-assembly-versions
2 years ago
All the different .dll visions exist in their own plugin and if you run the plugin in isolation it works
The problem comes when other Plugins are used that reference an older version
On nopCommerce Pluign install\startup all the plugin .dll files are copied to the \Bin directory
The version that is in the \Bin directory is the older version
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.