Hi @Michael Ribeiro Greetings! Welcome to Microsoft Q&A forum. Thank you for posting this question here.
Looking at the error stack, the error message seems to be originating from the Azure function. If you have deployed the function app on to Azure, you need to make sure you have provided a reference to the dependent packages. Starting with function app version 2.x+, you can refer the needed dependencies to the Function App by defining them in a file named function.json
The core tools build .csproj
file to install the required libraries. Here is an example of an extensions.csproj
file that adds a reference of external library to the Function App.
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.ProjectOxford.Face" Version="1.1.0" />
</ItemGroup>
</Project>
Please refer the documentation Using Nuget packages for more information.
Please also find a similar solution shared on the thread on how to use an SFTP client in Function app.
Hope this helps! If you run into any additional issues after trying the above steps, please reach out to us and we would be glad to assist you further.
Update
Changing the framework to 4.7.2 and then referencing Rebex.Ftp assembly worked. Using the external libraries with .Net 8.0 continues to produce this error
If the response helped, please do click Accept Answer and Yes for the answer provided. Doing so would help other community members with similar issue identify the solution. I highly appreciate your contribution to the community.