I have already installed Fody in my application several and several times but still this error appears below, could anyone tell me why it happens? I use the latest version of Visual Studio and latest version of Framework
Sometimes (for unknown reason) FodyWeavers.xml
cannot be added automatically when the package is added. You'll need to add it to the root of the project manually:
<?xml version="1.0" encoding="utf-8"?>
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
<Costura />
</Weavers>
I'm using Fody 4.2.1
and Costura.Fody 3.3.3
I hope it helps 😊
In my case, FodyWeavers.xml is already exists because the PropertyChanged.Fody library was installed. if this file exists, just add <Costura />
to it.
Before
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
<PropertyChanged />
</Weavers>
After
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
<PropertyChanged />
<Costura />
</Weavers>
I had same issue on my Cake script using MSBuild command and I solved that:
a) Applying EgoistDeveloper above tip
b) Cleaning ./bin and ./obj folder of all projects under my solution folder
c) Adding -t:Clean,Restore,... msbuild parameter command line
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With