third_party_pyyaml/lib3/yaml
Florian Bruhin 9959328b41 Import Hashable from collections.abc
In Python 3.7, importing ABCs directly from the 'collections' module shows a
warning (and in Python 3.8 it will stop working) - see
c66f9f8d39

Since this is only done in lib3/ which is Python 3 only, we can unconditionally
import it from collections.abc instead.

This fixes the following DeprecationWarning:

.../site-packages/yaml/__init__.py:75: in load
    return loader.get_single_data()
.../site-packages/yaml/constructor.py:37: in get_single_data
    return self.construct_document(node)
.../site-packages/yaml/constructor.py:46: in construct_document
    for dummy in generator:
.../site-packages/yaml/constructor.py:398: in construct_yaml_map
    value = self.construct_mapping(node)
.../site-packages/yaml/constructor.py:204: in construct_mapping
    return super().construct_mapping(node, deep=deep)
.../site-packages/yaml/constructor.py:126: in construct_mapping
    if not isinstance(key, collections.Hashable):
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

name = 'Hashable'

    def __getattr__(name):
        # For backwards compatibility, continue to make the collections ABCs
        # through Python 3.6 available through the collections module.
        # Note, no new collections ABCs were added in Python 3.7
        if name in _collections_abc.__all__:
            obj = getattr(_collections_abc, name)
            import warnings
            warnings.warn("Using or importing the ABCs from 'collections' instead "
                          "of from 'collections.abc' is deprecated, "
                          "and in 3.8 it will stop working",
>                         DeprecationWarning, stacklevel=2)
E           DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working
2019-02-27 18:06:38 -08:00
..
__init__.py Reverting https://github.com/yaml/pyyaml/pull/74 2018-06-30 15:46:56 -07:00
composer.py Fix typos 2017-08-08 06:05:28 -05:00
constructor.py Import Hashable from collections.abc 2019-02-27 18:06:38 -08:00
cyaml.py Reverting https://github.com/yaml/pyyaml/pull/74 2018-06-30 15:46:56 -07:00
dumper.py Reverting https://github.com/yaml/pyyaml/pull/74 2018-06-30 15:46:56 -07:00
emitter.py Fix typos 2017-08-08 06:05:28 -05:00
error.py scanner: use infinitive verb after auxiliary word could 2015-04-04 13:25:24 -03:00
events.py scanner: use infinitive verb after auxiliary word could 2015-04-04 13:25:24 -03:00
loader.py Reverting https://github.com/yaml/pyyaml/pull/74 2018-06-30 15:46:56 -07:00
nodes.py scanner: use infinitive verb after auxiliary word could 2015-04-04 13:25:24 -03:00
parser.py scanner: use infinitive verb after auxiliary word could 2015-04-04 13:25:24 -03:00
reader.py Remove commented out Psyco code 2018-04-11 10:02:31 -07:00
representer.py Improve RepresenterError creation 2017-08-08 06:02:01 -05:00
resolver.py Adding an implicit resolver to a derived loader should not affect the base loader (fixes issue #57). 2016-08-25 17:42:41 -05:00
scanner.py Support escaped slash in double quotes "\/" 2018-06-24 22:15:31 +02:00
serializer.py scanner: use infinitive verb after auxiliary word could 2015-04-04 13:25:24 -03:00
tokens.py scanner: use infinitive verb after auxiliary word could 2015-04-04 13:25:24 -03:00