Azure / azure-functions-durable-extension

Durable Task Framework extension for Azure Functions
MIT License
715 stars 271 forks source link

Debugging Options: "Enable Just My Code" ignored for Durable Functions #872

Closed paulpce closed 5 years ago

paulpce commented 5 years ago

Description

When debugging durable functions, I'm constantly hammered by "xxxxx.cs not found" messages while trying to debug. The "Enable Just My Code" debugging option is enabled.

Expected behavior

I should be able to set breakpoints in my code and debug only my code without being interrupted by file not found messages when "Enable Just My Code" is on.

Actual behavior

When debugging durable functions, I'm constantly hammered by "xxxxx.cs not found" messages of various DF class source files. I have the "Enable Just My Code" option switched on, but it still insists on trying to debug DF source code as well. Examples of files regularly seen: TriggeredFunctionExecutor.cs FunctionResult.cs FunctionAssemblyLoadContext.cs FileLogger.cs ScriptLoggingBuilderExtensions.cs

I need to push through sometimes 10, sometimes many dozens of these messages at a time to debug through a complex series of orchestrations and activities. It is frustrating and time consuming.

App Details

cgillum commented 5 years ago

These are not Durable Functions source files, these are Azure Functions (WebJobs) runtime source files.

@fabiocav could this be because the shipped WebJobs SDK packages are compiled in debug mode instead of release mode? I recall a thread on this kind of issue recently.

paulpce commented 5 years ago

these are Azure Functions (WebJobs) runtime source files

Ah, my apologies. I should have checked that. I haven't seen the same thing running the non-durable functions in my solution so assumed they were all DF source files. I have Microsoft.Azure.WebJobs v3.0.8 installed as a dependency in all my Azure Functions projects, including the one with Durable Functions extension.

I found this recent issue which seems to be what you were referring to. Happy to close this issue if it's confirmed that's the problem.

paulpce commented 5 years ago

On reflection, I think the issue has just been exacerbated in Durable Functions because of the constant entry/exit/replay while debugging. I probably would not have hit the issue in the other functions.

fabiocav commented 5 years ago

Yes. We're tracking that with and will have the updated packages released soon https://github.com/Azure/azure-webjobs-sdk/issues/2261

Please track that issue for updates.

paulpce commented 5 years ago

Thanks!