fnproject / fdk-python

Python Function Development Kit
http://fnproject.io/
Apache License 2.0
45 stars 24 forks source link

Exception in callback HttpProtocol.keep_alive_timeout_callback() #103

Closed kocic11 closed 4 years ago

kocic11 commented 4 years ago

Description

Getting an exception whenever running the function for the first time or after a certain period of time, currently 5 minutes.

Steps to reproduce the issue:

  1. Deploy function.
  2. Invoke function
  3. Observe the output

Describe the results you received: Getting the following error: 2020-03-13 15:52:24,647 - asyncio - ERROR - Exception in callback HttpProtocol.keep_alive_timeout_callback() handle: <TimerHandle when=15787.202277142 HttpProtocol.keep_alive_timeout_callback()> Traceback (most recent call last): File "/usr/local/lib/python3.6/asyncio/events.py", line 145, in _run self._callback(*self._args) File "/python/fdk/async_http/protocol.py", line 239, in keep_alive_timeout_callback time_elapsed = current_time - self._last_response_time TypeError: unsupported operand type(s) for -: 'NoneType' and 'NoneType'

Describe the results you expected: No errors

Additional information you deem important (e.g. issue happens only occasionally): This error happens only on the first run. The function executes correctly. Output of FDK version (PIP output):

0.1.12

Additional environment details (python version, code sample, etc.): Python 3.6.8

mrc commented 4 years ago

This should be fixed in FDK 0.1.18: https://pypi.org/project/fdk/0.1.18/

Please feel free to reopen this issue if it reoccurs after updating the FDK.