From ed71db853aec4eda36f7e0f2b1d046bdb7c3784b Mon Sep 17 00:00:00 2001 From: Richard Marmorstein Date: Mon, 26 Aug 2024 12:42:10 -0700 Subject: [PATCH] Update http client comment --- stripe/_http_client.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/stripe/_http_client.py b/stripe/_http_client.py index f7969a5b5..6622b500a 100644 --- a/stripe/_http_client.py +++ b/stripe/_http_client.py @@ -39,10 +39,12 @@ Never, ) -# - Requests is the preferred HTTP library -# - Google App Engine has urlfetch -# - Use Pycurl if it's there (at least it verifies SSL certs) -# - Fall back to urllib2 with a warning if needed + +# The precedence of HTTP libraries is +# - Urlfetch (this is provided by Google App Engine, so if it's present you probably want it) +# - Requests (popular library, the top priority for all environments outside Google App Engine, but not always present) +# - Pycurl (another library, not always present, not as preferred as Requests but at least it verifies SSL certs) +# - urllib2 with a warning (basically always present, fallback if needed) try: import urllib.request as urllibrequest import urllib.error as urlliberror