I'm trying to search a webpage using regular expressions, but I'm getting the following error:
TypeError: can't use a string pattern on a bytes-like object
You just need to decode the response, using the
Content-Type header typically the last value. There is an example given in the tutorial too.
output = response.decode('utf-8')