question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Node worker did not start properly ('30' second timeout)

See original GitHub issue

I have a Logic App Standard workflow that includes the Inline Code action. Starting this week I get the following exception when I try to run the logic app locally. This used to work fine for at least a week or three. I don’t know what changed or what I can do to further investigate. I verified I have the right NodeJS version installed.

VS Code version: 1.68.1 Node.js: 16.13.0 Azure Logic Apps (Standard) extension: 1.0.19 Function Runtime Version: 4.0.1.1681 OS: Windows_NT x64 10.0.19044

[2022-07-05T12:50:46.957Z] Host lock lease acquired by instance ID '000000000000000000000000A3ABDEE2'.
[2022-07-05T12:51:12.987Z] Workflow Error: operationName='WorkflowDefinitionProvider.ProcessWorkflow', message='Workflow 'SendTagReport' validate and create workflow operation failed, the exception is 'The input 
parameter 'code' for inline code action 'E-mail_body' contains invalid code. Parsing the code failed with 
error 'Node worker did not start properly ('30' second timeout).'.'', exception='Microsoft.Azure.Workflows.Common.ErrorResponses.ErrorResponseMessageException: The input parameter 'code' for inline code action 'E-mail_body' contains invalid code. Parsing the code failed with error 'Node worker did not start properly 
('30' second timeout).'.
[2022-07-05T12:51:12.989Z]  ---> Microsoft.Azure.Workflows.Common.ErrorResponses.ErrorResponseMessageException: Node worker did not start properly ('30' second timeout).
[2022-07-05T12:51:12.991Z]    at Microsoft.Azure.Workflows.Languages.Edge.JScript.Engines.NodeProcessHandler.StartNodeProcess()
[2022-07-05T12:51:12.993Z]    at Microsoft.Azure.Workflows.Languages.Edge.JScript.Engines.NodeProcessHandler.StartNodeProcessIfNotStarted()
[2022-07-05T12:51:12.994Z]    at Microsoft.Azure.Workflows.Languages.Edge.JScript.Engines.JavascriptAnalysisEngine.FindDependencies(String actionName, String javascript)
[2022-07-05T12:51:12.996Z]    at Microsoft.Azure.Workflows.Web.Engines.EdgeFlowWebManagementEngine.GetActionDependencies(String actionName, String actionCode)
[2022-07-05T12:51:12.998Z]    --- End of inner exception stack trace ---
[2022-07-05T12:51:12.999Z]    at Microsoft.Azure.Workflows.Web.Engines.EdgeFlowWebManagementEngine.GetActionDependencies(String actionName, String actionCode)
[2022-07-05T12:51:13.001Z]    at Microsoft.Azure.Workflows.Web.Engines.EdgeFlowWebManagementEngine.<GetInlineCodeActionsGeneratedDependencies>b__10_3(KeyValuePair`2 actionKvp)
[2022-07-05T12:51:13.003Z]    at Microsoft.WindowsAzure.ResourceStack.Common.Extensions.ConcurrencyExtensions.AggregateOperationsConcurrently[TElement,TResult,TAccumulate](IEnumerable`1 source, Func`2 operation, 
TAccumulate seed, Func`3 accumulator, Int32 concurrencyLimit, CancellationToken cancellationToken)        
[2022-07-05T12:51:13.005Z]    at Microsoft.Azure.Workflows.Web.Engines.EdgeFlowWebManagementEngine.GetInlineCodeActionsGeneratedDependencies(FlowPropertiesDefinition definition)
[2022-07-05T12:51:13.006Z]    at Microsoft.Azure.Workflows.Web.Engines.EdgeFlowWebManagementEngine.GetTemplateRuntimeContext(FlowPropertiesDefinition definition, String flowName, Flow existingFlow, EdgeConnectionReferencesDefinition edgeConnectionReferencesDefinition)
[2022-07-05T12:51:13.008Z]    at Microsoft.Azure.Workflows.Web.Engines.EdgeFlowWebManagementEngine.ValidateAndCreateFlow(String flowName, FlowPropertiesDefinition flowPropertiesDefinition)
[2022-07-05T12:51:13.010Z]    at Microsoft.WindowsAzure.ResourceStack.Common.Algorithms.AsyncRetry.Retry(Func`1 action, Int32 retryCount, TimeSpan retryInterval, CancellationToken cancellationToken, Nullable`1 retryTimeout, Func`2 isRetryable, Action`1 errorAction, Func`2 retryAfter)
[2022-07-05T12:51:13.012Z]    at Microsoft.WindowsAzure.ResourceStack.Common.Algorithms.AsyncRetry.Retry(Func`1 action, Int32 retryCount, TimeSpan retryInterval, CancellationToken cancellationToken, Nullable`1 retryTimeout, Func`2 isRetryable, Action`1 errorAction, Func`2 retryAfter)
[2022-07-05T12:51:13.014Z]    at Microsoft.Azure.Workflows.WebJobs.Extensions.Initialization.WorkflowFunctionDefinitionProvider.ProcessWorkflow(FlowFunction flowFunction, ConcurrentDictionary`2 flowsProcessed)', 
extensionVersion='1.0.0.0', siteName='UNDEFINED_SITE_NAME', slotName='', activityId='ef07a91a-8c90-4665-8db4-15909fc495f0'.

AB#15956329

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:2
  • Comments:5

github_iconTop GitHub Comments

1reaction
TonnyWildemancommented, Sep 8, 2022

So, I dug a little deeper and found the reason why the node js analysis service is not starting. The code is being called with the following cmd line:

 node index.js 60461 334681,4167

In index.js the line

let timeout = setTimeout(() => process.kill(process.pid, 'SIGTERM'), timeoutDurationInMilliseconds);

immediately invokes, because the string 334681,4167 is being converted due to implicit type coercion to 0. Thus invoke immediately: https://developer.mozilla.org/en-US/docs/Web/API/setTimeout#non-number_delay_values_are_silently_coerced_into_numbers

0reactions
github-actions[bot]commented, Oct 20, 2022

This issue is stale because it has been open for 30 days with no activity.

Read more comments on GitHub >

github_iconTop Results From Across the Web

A Complete Guide to Timeouts in Node.js
Assigning timeout values prevents network operations in Node.js from blocking indefinitely. This article provides extensive instruction on ...
Read more >
Logic App Failing with error "the server did not respond ...
My Logic app was working fine until Sept 21 but it is now failing with error -the server did not respond within the...
Read more >
Top 10 Most Common Node.js Developer Mistakes
Mistake #4: Expecting Callbacks to Run Synchronously. Asynchronous programming with callbacks may not be something unique to JavaScript and Node.js, but they ...
Read more >
Standard logic app run timeout setting is not working
Backend.FlowRunTimeout setting in host settings to 30 seconds. Stopped, Restarted logic app; Added delay for 1 minute in HTTP trigger logic app.
Read more >
npm install timing out fetching @typescript-eslint ...
While we investigate the timeout issue, as a workaround you could add another npm install script right after the first one and only...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found