Tribler/py-ipv8

`aiohttp_apispec` `web.AppKey` warnings

qstokkink opened this issue · 3 comments

When running IPv8 or its unit tests, we get the following warning(s):

aiohttp_apispec/aiohttp_apispec.py:75: UserWarning: It is recommended to use web.AppKey instances for keys.
https://docs.aiohttp.org/en/stable/web_advanced.html#application-s-config
  app["_apispec_request_data_name"] = self._request_data_name
aiohttp_apispec/aiohttp_apispec.py:79: UserWarning: It is recommended to use web.AppKey instances for keys.
https://docs.aiohttp.org/en/stable/web_advanced.html#application-s-config
  app["_apispec_parser"] = parser
aiohttp_apispec/aiohttp_apispec.py:143: UserWarning: It is recommended to use web.AppKey instances for keys.
https://docs.aiohttp.org/en/stable/web_advanced.html#application-s-config
  app["swagger_dict"] = self.swagger_dict()

These warnings should be addressed in some way (by either adopting the advice or muting them).

Actually, these warnings have very little to do with our code: they are inside of our aiohttp_apispec dependency.

Upon further inspection, https://github.com/maximdanilchenko/aiohttp-apispec has not been updated in the last 10 months. The project might be dead. If so, it is unlikely that these warnings will be fixed.

For now, everything still works. However, this does not bode well and we should probably start thinking of a "Plan B". Just in case aiohttp_apispec does end up in disrepair.

If we end up having to switch, if seems like FastAPI offers roughly the same functionality that we use now.