python-elasticsearch-logger icon indicating copy to clipboard operation
python-elasticsearch-logger copied to clipboard

enum34: KeyError in _INDEX_FREQUENCY_FUNCION_DICT lookup

Open tacsnack opened this issue 6 years ago • 0 comments

With enum34 installed (due to other dependencies in a common environment) a KeyError is raised doing the _INDEX_FREQUENCY_FUNCION_DICT lookup.

    self._index_name_func = CMRESHandler._INDEX_FREQUENCY_FUNCION_DICT[self.index_name_frequency]
KeyError: 0

This occurs due to the fact that enum.py treated enums as ints and enum34 treats them as the class. Happy to help resolve this one as this will be a step to making this package py3 compatible potentially.

Thanks for your work on this. A really great package.

tacsnack avatar Dec 07 '18 23:12 tacsnack