Skip to content

Remove @staticmethod from functions outside classes #65

@anthonychu

Description

@anthonychu

Got some of these errors accessing functions in http_util.py due to @staticmethod decorator on functions outside classes:

Microsoft.Azure.WebJobs.Host.FunctionInvocationException: Exception while executing function: Functions.HttpTrigger
 ---> Microsoft.Azure.WebJobs.Script.Workers.Rpc.RpcException: Result: Failure
Exception: TypeError: 'staticmethod' object is not callable
Stack:   File "/azure-functions-host/workers/python/3.7/LINUX/X64/azure_functions_worker/dispatcher.py", line 312, in _handle__invocation_request
    call_result = await fi.func(**args)
  File "/home/site/wwwroot/HttpTrigger/__init__.py", line 9, in main
    instance_id = await client.start_new("HelloOrchestrator", None, "Seattle")
  File "/usr/local/lib/python3.7/site-packages/azure/durable_functions/models/DurableOrchestrationClient.py", line 71, in start_new
    response = await self._post_async_request(request_url, self._get_json_input(client_input))
  File "/usr/local/lib/python3.7/site-packages/azure/durable_functions/models/DurableOrchestrationClient.py", line 40, in <lambda>
    self._post_async_request = lambda u, d: post_async_request(u, d)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions