callHttp
long polling returning error: Reason: Message: Converting circular structure to JSON
#571
Description
Describe the bug
A clear and concise description of what the bug is. Please make an effort to fill in all the sections below; the information will help us investigate your issue.
[2024-01-16T15:51:59.285Z] 7acf0ea4b92e43768c23ebc80ce819eb: Function 'orchestrator (Orchestrator)' failed with an error. Reason: Message: Converting circular structure to JSON
[2024-01-16T15:51:59.285Z] --> starting at object with constructor 'CallHttpWithPollingTask'
[2024-01-16T15:51:59.285Z] | property 'children' -> object with constructor 'Array'
[2024-01-16T15:51:59.285Z] | index 0 -> object with constructor 'AtomicTask'
[2024-01-16T15:51:59.285Z] --- property 'parent' closes the circle, StackTrace: at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
[2024-01-16T15:51:59.285Z] at System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
[2024-01-16T15:51:59.285Z] at Microsoft.Azure.WebJobs.Extensions.DurableTask.TaskOrchestrationShim.InvokeUserCodeAndHandleResults(RegisteredFunctionInfo orchestratorInfo, OrchestrationContext innerContext) in D:\a\_work\1\s\src\WebJobs.Extensions.DurableTask\Listener\TaskOrchestrationShim.cs:line 150. IsReplay: False. State: Failed. RuntimeStatus: Failed. HubName: TestHubName. AppName: . SlotName: . ExtensionVersion: 2.13.0. SequenceNumber: 5. TaskEventId: -1
Investigative information
- Durable Functions extension version:
2.13.0
- durable-functions npm module version:
3.0.0
- Language (JavaScript/TypeScript) and version: TS
4.9.5
- Node.js version: 18
If deployed to Azure App Service
- Timeframe issue observed:
- Function App name:
- Function name(s):
- Region:
- Orchestration instance ID(s):
If you don't want to share your Function App name or Functions names on GitHub, please be sure to provide your Invocation ID, Timestamp, and Region - we can use this to look up your Function App/Function. Provide an invocation id per Function. See the Functions Host wiki for more details.
To Reproduce
Steps to reproduce the behavior:
- Create an http call that triggers the long polling pattern
While not required, providing your orchestrator's source code in anonymized form is often very helpful when investigating unexpected orchestrator behavior.
context.df.callHttp({
method: 'POST',
url: url,
body: input,
});
Expected behavior
A clear and concise description of what you expected to happen.
Actual behavior
A clear and concise description of what actually happened.
Screenshots
If applicable, add screenshots to help explain your problem.
Known workarounds
Provide a description of any known workarounds you used.
Additional context
- Development environment (ex. Visual Studio)
- Links to source
- Additional bindings used
- Function invocation IDs