We have an python application using httpx (v0.27.0). The applications uses httpx to open https connecto to AWS api gateway. This has been stable and working for years. Recently we will see a random error on connection:
httpcore.ConnectError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1000)
The error is intermittent. Some requests work and some don't. There is only one instance of this app in ECS so it is not load balancing issue. The strange part if we restart the docker container with this python app the issue gets resolved for a few days and then slowly creeps back.
It is almost like something is being chached or pooled. However, from documentation we don't see anything that would cause this. We use default httpx client settings.
Any ideas?