Mercurial > repos > shellac > guppy_basecaller
comparison env/lib/python3.7/site-packages/setuptools/py27compat.py @ 2:6af9afd405e9 draft
"planemo upload commit 0a63dd5f4d38a1f6944587f52a8cd79874177fc1"
| author | shellac |
|---|---|
| date | Thu, 14 May 2020 14:56:58 -0400 |
| parents | 26e78fe6e8c4 |
| children |
comparison
equal
deleted
inserted
replaced
| 1:75ca89e9b81c | 2:6af9afd405e9 |
|---|---|
| 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""" |
