The simplest way is to “shim” the session’s request function:
import requests
import functools
s = requests.Session()
s.request = functools.partial(s.request, timeout=3)
# now all get, post, head etc requests should timeout after 3 seconds
# following will fail
s.get('https://httpbin.org/delay/6')
# we can still pass higher timeout when needed
# following will succeed
s.get('https://httpbin.org/delay/6', timeout=7)