This repository was archived by the owner on Oct 14, 2023. It is now read-only.

Description
Successfully deployed the http trigger sas token generator to azure but when I test it using the azure test utility the console gives the following error.
2019-06-07T12:11:57.118 [Information] Executing 'Functions.GLNorton287Func' (Reason='This function was programmatically called via the host APIs.', Id=00cf0c14-75be-4070-b48e-292dfcefd3ae)
2019-06-07T12:11:57.222 [Information] Python HTTP trigger function processed a request.
2019-06-07T12:11:57.251 [Information] Executed 'Functions.GLNorton287Func' (Succeeded, Id=00cf0c14-75be-4070-b48e-292dfcefd3ae)ailure
Exception: UnboundLocalError: local variable 'req_body' referenced before assignment
Stack: File "/home/site/wwwroot/.python_packages/lib/python3.6/site-packages/azure/functions_worker/dispatcher.py", line 300, in _handle__invocation_request
self.__run_sync_func, invocation_id, fi.func, args)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/home/site/wwwroot/.python_packages/lib/python3.6/site-packages/azure/functions_worker/dispatcher.py", line 389, in __run_sync_func
return func(**params)
File "/home/site/wwwroot/GLNorton287Func/__init__.py", line 164, in main
permission = req_body.get('permission')
Any ideas why this is happening?
Thank you
John