Closed rich-sykes closed 2 months ago
Thanks for reporting will check and update. pls share function invocation id,timestamp,region etc.
Can you share the work load that your function app is doing? The host starts the Python worker and if the initialization doesn't complete within 5 seconds, then the timeout occurs.
Initialization comprises of worker initialization, function being indexed (for V2 model) and loading of functions (V1 model). And if all the operations do not complete within the timeout period, this gets caused.
Thank you for the response @vrdmr, to simplify debugging even if I use the example here docs. When pushed Az the function app runs fine online so I confident the workload might not be the cause.
func new --template "Http Trigger" --name MyHttpTrigger
Using V2 model:
{
"version": "2.0",
"logging": {
"applicationInsights": {
"samplingSettings": {
"isEnabled": true,
"excludedTypes": "Request"
}
}
},
"extensionBundle": {
"id": "Microsoft.Azure.Functions.ExtensionBundle",
"version": "[4.*, 5.0.0)"
}
}
Add a simple http trigger:
import azure.functions as func
import datetime
import json
import logging
app = func.FunctionApp()
@app.route(route="MyHttpTrigger", auth_level=func.AuthLevel.ANONYMOUS)
def MyHttpTrigger(req: func.HttpRequest) -> func.HttpResponse:
logging.info('Python HTTP trigger function processed a request.')
name = req.params.get('name')
if not name:
try:
req_body = req.get_json()
except ValueError:
pass
else:
name = req_body.get('name')
if name:
return func.HttpResponse(f"Hello, {name}. This HTTP triggered function executed successfully.")
else:
return func.HttpResponse(
"This HTTP triggered function executed successfully. Pass a name in the query string or in the request body for a personalized response.",
status_code=200
)
@bhagyshricompany @vrdmr - this was actually a security agent running on the MacBook which was blocking the gRPC from initialising. Thank you for the support.
Investigative information
Please can I get some help resolving GPRC timeout when trying to run Azure Function runner. This has been carried out on a clean MacOS ARM64 build
Please provide the following:
Repro steps
func init MyProjFolder --worker-runtime python --model V2
cd MyProjFolder
func new --template "Http Trigger" --name MyHttpTrigger
func start --debug --verbose
Expected behavior
Azure Functions Core Tools starts and functions are available.
Actual behavior
Known workarounds
None found yet.
Contents of the requirements.txt file:
Provide the requirements.txt file to help us find out module related issues.
Related information
Provide any related information
This is on a clean MacOS 13.6 build using homebrew.