Mercurial > repos > guerler > springsuite
comparison planemo/lib/python3.7/site-packages/setuptools/py27compat.py @ 1:56ad4e20f292 draft
"planemo upload commit 6eee67778febed82ddd413c3ca40b3183a3898f1"
| author | guerler |
|---|---|
| date | Fri, 31 Jul 2020 00:32:28 -0400 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 0:d30785e31577 | 1:56ad4e20f292 |
|---|---|
| 1 """ | |
| 2 Compatibility Support for Python 2.7 and earlier | |
| 3 """ | |
| 4 | |
| 5 import platform | |
| 6 | |
| 7 from setuptools.extern import six | |
| 8 | |
| 9 | |
| 10 def get_all_headers(message, key): | |
| 11 """ | |
| 12 Given an HTTPMessage, return all headers matching a given key. | |
| 13 """ | |
| 14 return message.get_all(key) | |
| 15 | |
| 16 | |
| 17 if six.PY2: | |
| 18 def get_all_headers(message, key): | |
| 19 return message.getheaders(key) | |
| 20 | |
| 21 | |
| 22 linux_py2_ascii = ( | |
| 23 platform.system() == 'Linux' and | |
| 24 six.PY2 | |
| 25 ) | |
| 26 | |
| 27 rmtree_safe = str if linux_py2_ascii else lambda x: x | |
| 28 """Workaround for http://bugs.python.org/issue24672""" |
