mirror of
https://github.com/kennethreitz/requests.git
synced 2026-06-05 06:46:15 +00:00
24 lines
480 B
Python
24 lines
480 B
Python
import warnings
|
|
|
|
try:
|
|
import StringIO
|
|
except ImportError:
|
|
import io as StringIO
|
|
|
|
try:
|
|
from cStringIO import StringIO as cStringIO
|
|
except ImportError:
|
|
cStringIO = None
|
|
|
|
|
|
def u(s):
|
|
warnings.warn(
|
|
(
|
|
"This helper function is no longer relevant in Python 3. "
|
|
"Usage of this alias should be discontinued as it will be "
|
|
"removed in a future release of Requests."
|
|
),
|
|
DeprecationWarning,
|
|
)
|
|
return s
|