assembly-binding-redirect

Azure Functions binding redirect

☆樱花仙子☆ 提交于 2019-12-17 09:34:00
问题 Is it possible to include a web.config or app.config file in the azure functions folder structure to allow assembly binding redirects? 回答1: Assuming you are using the latest (June'17) Visual Studio 2017 Function Tooling, I derived a somewhat-reasonable config-based solution for this following a snippet of code posted by npiasecki over on Issue #992. It would be ideal if this were managed through the framework, but at least being configuration-driven you have a bit more change isolation. I

Azure Functions binding redirect

懵懂的女人 提交于 2019-12-17 09:33:03
问题 Is it possible to include a web.config or app.config file in the azure functions folder structure to allow assembly binding redirects? 回答1: Assuming you are using the latest (June'17) Visual Studio 2017 Function Tooling, I derived a somewhat-reasonable config-based solution for this following a snippet of code posted by npiasecki over on Issue #992. It would be ideal if this were managed through the framework, but at least being configuration-driven you have a bit more change isolation. I

Incompatible .NET Standard assemblies that should have been compatible?

这一生的挚爱 提交于 2019-12-12 12:49:57
问题 I have a .NET Standard 2.0 DLL project. It has no other references, apart from NETStandard.Library 2.0.1 and all is fine. It is referenced by a WPF application and everything seems to work fine. Once I add a nuget package for System.Collections.Immutable 1.5.0 to the DLL project, a yellow exclamation mark appears on the Dependencies root of the Solution Explorer. (Hm... I now see that the exclamation remains even after I remove this package, but I guess this is a VS bug since everything

Why doesn't bindingRedirect affect FSharp.Core version

陌路散爱 提交于 2019-12-10 18:26:32
问题 I have a unit test project that targets F# runtime 4.4.1. It has an app.config with the bindingRedirect section: <dependentAssembly> <Paket>True</Paket> <assemblyIdentity name="FSharp.Core" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> <bindingRedirect oldVersion="0.0.0.0-65535.65535.65535.65535" newVersion="4.4.1.0" /> </dependentAssembly> However, when I run tests I get a runtime error: Could not load file or assembly 'FSharp.Core, Version=4.3.0.0, Culture=neutral, PublicKeyToken

How do I redirect assembly binding to the current version or higher?

此生再无相见时 提交于 2019-12-10 14:58:38
问题 Even though my references have Specific Version set to false , I'm getting assembly binding errors because the target machine has a higher version. How do I specify the current version or higher to avoid the following error when some target machines might have version 1.61.0.0 while others have 1.62.0.0 or higher? System.IO.FileLoadException: Could not load file or assembly 'ServerInterface.NET, Version=1.61.0.0, Culture=neutral, PublicKeyToken=151ae431f239ddf0' or one of its dependencies.

Assembly binding redirect in Azure Functions

∥☆過路亽.° 提交于 2019-12-10 13:19:59
问题 I have created an Azure function and as we know it has the package Microsoft.NET.Sdk.Functions 1.0.8 which is dependent on Newtonsoft.Json 9.0.1. I have added another class library as a reference to this Azure Function which depends on Newtonsoft.Json 11.0.2. During runtime, I get an error stating: "FileNotFoundException: Could not load file or assembly 'Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the

Referencing multiple versions of the same assembly

孤人 提交于 2019-12-10 12:08:00
问题 Is it possible to have multiple versions of the same strongly named assembly loaded in the same process? There is plenty of similar questions, but non of the answers seem to work. The reason I'm asking is we need to use newer version (4.0.0.0) of SomeAssembly.dll , but some referenced dlls depend on the older version (3.0.0.0) of this dll. I have tried using the below assembly binding redirection configuration, but ended up with compilation errors, because my assemblies depend on a newer

Using relative path in assemblyBindig/linkedConfiguration element

白昼怎懂夜的黑 提交于 2019-12-10 03:59:27
问题 I'm trying to move assembly redirects from web.config into an external file. The reason for it is that I want to keep binding redirect in one place and use it on both debug and production configurations. It sort of works, but I'm strugling with specifying relative paths. <configuration> <!-- this works, but forces me to use the same path on dev and production machines --> <linkedConfiguration href="file://c:\data\web.runtime.config"/> <!-- none of those works --> <linkedConfiguration href=

Could not load file or assembly 'System.ComponentModel.Annotations' in published .Net 4.6.1 project referencing .Net Standard library

最后都变了- 提交于 2019-12-05 11:43:28
PLEASE NOTE : This is not a duplicate of Could not load file or assembly 'System.ComponentModel.Annotations, Version=4.1.0.0 . Unlike the issue linked, this issue occurs only after publishing the application. As you will see below, I have tried every solution proposed in that post with no success. This issue occurs in a WPF .Net Framework 4.6.1 project which references a .Net Standard 2.0 library which itself references the System.ComponentModel.Annotations NuGet package. The issue is reproduced in the following project: https://github.com/kaitlynbrown/DataAnnotationsError To reproduce the

Asp core wrong assembly redirect on publish

我的未来我决定 提交于 2019-12-05 02:31:54
When publishing my asp core project using visual studio a .config file is created alongside my executable. The .config includes a couple of bindingRedirect like this: <?xml version="1.0" encoding="utf-8"?> <configuration> <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <dependentAssembly> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /> <bindingRedirect oldVersion="6.0.0.0" newVersion="8.0.0.0" /> <bindingRedirect oldVersion="7.0.0.0" newVersion="8.0.0.0" /> <bindingRedirect oldVersion="6.0.0.0" newVersion="9.0.0.0" />