Aiohttp doesn't return any error on invalid request methods #4798
Closed
Description
🐞 Describe the bug
I ran the simple server example located in https://github.com/aio-libs/aiohttp/blob/master/examples/server_simple.py
Then sent an invalid GET1 request using CURL. There is no response from aiohttp and curl is blocked.
The original error was reported there: GNS3/gns3-server#1766 (GNS3 server uses aiohttp).
💡 To Reproduce
$ curl -X GET1 http://0.0.0.0:8080/
<no response, blocks until killed>💡 Expected behavior
An HTTP error.
📋 Your version of the aiohttp distribution
$ python3 -m pip show aiohttp
Name: aiohttp
Version: 3.6.2
Summary: Async http client/server framework (asyncio)
Home-page: https://github.com/aio-libs/aiohttp
Author: Nikolay Kim
Author-email: fafhrd91@gmail.com
License: Apache 2
Location: /usr/local/lib/python3.6/dist-packages
Requires: typing-extensions, chardet, multidict, idna-ssl, attrs, async-timeout, yarl
Required-by: aiohttp-cors, pytest-aiohttp, gns3-server