Worker failed to index functions
Result: Failure
Exception: AttributeError: anonymous
It appears that the function decorator is not generated correctly: It should be @app.route(route="HttpExample", auth_level=func.AuthLevel.ANONYMOUS) instead of @app.route(route="HttpExample", auth_level=func.AuthLevel.Anonymous).
On https://learn.microsoft.com/en-us/azure/azure-functions/create-first-function-cli-python?tabs=linux%2Cbash%2Cazure-cli%2Cbrowser#create-a-local-function it is explained that a new function can be created with the command
func new --name HttpExample --template "HTTP trigger" --authlevel "anonymous"
. However, this executing this command generates invalid code. When trying to runfunc start
afterwards, an exception is raised:It appears that the function decorator is not generated correctly: It should be
@app.route(route="HttpExample", auth_level=func.AuthLevel.ANONYMOUS)
instead of@app.route(route="HttpExample", auth_level=func.AuthLevel.Anonymous)
.