unable to start DFM after updating dotnet version(?)
Durable Functions Monitor extension has been working fine for me since I installed it until for an unrelated issue, I updated my Azure Function Core Tools and probably dotnet versions (I tried a bunch of things, I don't remember all that I did), and now I get this error every time I try to open a Durable Function:
Func: Could not load file or assembly 'Microsoft.Extensions.Configuration.Json, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. The system cannot find the file specified.
Current dotnet SDK version: 9.0.203 Current Core Tools version: 4.0.7030
Note: I also have dotnet SDK 6.0.428 installed and I tried to make the extension point to that one using a global.json file but that did not seem to work. Also tried to run different backends, to always end up with that same error. I am out of ideas, any suggestion will be appreciated.
@KDNRCan , does any durable function work on this machine now?
Can you post the whole output from Durable Functions Monitor channel (omitting sensitive data) ?
@KDNRCan , does any durable function work on this machine now?
Can you post the whole output from
Durable Functions Monitorchannel (omitting sensitive data) ?
@scale-tone yes, I am able to run durable functions on my computer, with .NET 6 in-process and .NET8 isolated (that's the unrelated change I was making and updated everything I had installed for). I run everything from Visual Studio though, I never tried to run them from VSCode, maybe it makes a difference.
As for the whole output, I get this at the start once (I never needed to install npm, so I don't have it):
npm list -g failed. Command failed: npm list -g --depth=0
'npm' is not recognized as an internal or external command,
operable program or batch file.
Then every time I try to open one of my durable functions:
Using Functions host: C:\Program Files\Microsoft\Azure Functions Core Tools\func.exe
Attempting to start the backend from C:/Users/<user>/.vscode/extensions/durablefunctionsmonitor.durablefunctionsmonitor-6.6.0/custom-backends/dotnetIsolated on http://localhost:37072/a/p/i...ERROR: Could not load file or assembly 'Microsoft.Extensions.Configuration.Json, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. The system cannot find the file specified.
There is not much there to work with...
Using Functions host: C:\Program Files\Microsoft\Azure Functions Core Tools\func.exe
Does this match the path to func.exe that is being used when you successfully run your durable functions ?
If not, can you try to provide the full path to the 'working' func.exe via this setting:
and see if it makes a difference?
@scale-tone we experience the same issue as OP and after installing a previous version of the azure functions core tools and referencing this in "Custom Path To Azure Functions Host" it works.
It works on func --version 4.0.6543 It does not work on func --version 4.0.7030
Are there any updates to this issue?
It does not work on func --version 4.0.7030
@nsk-jyskefinans-dk , does any other Functions project work on that func version on that machine?
@KDNRCan , in your trace I just noticed this:
Attempting to start the backend from C:/Users/
/.vscode/extensions/durablefunctionsmonitor.durablefunctionsmonitor-6.6.0/custom-backends/dotnetIsolated on http://localhost:37072/a/p/i...ERROR: Could not load file or assembly 'Microsoft.Extensions.Configuration.Json, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. The system cannot find the file specified.
This is not the default behavior of DfMon VsCode ext. The default backend path to be used is c:\Users\<username>\.vscode\extensions\durablefunctionsmonitor.durablefunctionsmonitor-6.6.0\backend .
Have you changed the Custom Path to Azure Functions Host setting?
What was the reason for that change?
Can you revert that config change back to default, restart VsCode and try again?
Folks, can we still help you both with this issue?
Folks, can we still help you both with this issue?
@scale-tone for my part, I am sorry I would not answer before, I was put on another project and wasn't able to try these out, but I finally came back to it and I had another error with it so I ended up uninstalling everything and re-upgrading to the new latest versions and now it works. I am not sure if that means there was a fix or if somehow my installations were corrupted before... Thank you for the help.
Closing, as there are also no new answer from the other commenter.