# Path: dataimporter/providers/wowtools.py
# def csv_to_list(csv_text, **kwargs):
#     def __init__(self):
#     async def __aenter__(self):
#     async def __aexit__(self, exc_type, exc_value, tb):
#     async def get_table_versions(self, table_name):
#     async def get_matching_build_version(self, table_name, build=None):
#     async def get_table(self, table_name, build=None):
#     async def get_file_list(self):
# def get_table(table_name, build=None):
#     async def _get_table():
# class WowToolsClient:


from .providers import wowtools


class WowToolsFixer:
    """Base class for Wowtools-based data fixers."""
    load_files = False

    def __init__(self, *args, build=None):
        self.build = build
        self._store_init(*args)
        if self.load_files:
            self.wt_files = {
                int(e['ID']): e for e in self.wt_get_table('files')
            }

    def _store_init(self, *args):
        raise NotImplementedError

    def run(self):
        raise NotImplementedError

    def wt_get_table(self, table_name):

# Path: dataimporter/providers/wowtools.py
# def csv_to_list(csv_text, **kwargs):
#     def __init__(self):
#     async def __aenter__(self):
#     async def __aexit__(self, exc_type, exc_value, tb):
#     async def get_table_versions(self, table_name):
#     async def get_matching_build_version(self, table_name, build=None):
#     async def get_table(self, table_name, build=None):
#     async def get_file_list(self):
# def get_table(table_name, build=None):
#     async def _get_table():
# class WowToolsClient:


# Path: dataimporter/fixer.py
from .providers import wowtools



class WowToolsFixer:
    """Base class for Wowtools-based data fixers."""
    load_files = False

    def __init__(self, *args, build=None):
        self.build = build
        self._store_init(*args)
        if self.load_files:
            self.wt_files = {
                int(e['ID']): e for e in self.wt_get_table('files')
            }

    def _store_init(self, *args):
        raise NotImplementedError

    def run(self):
        raise NotImplementedError

    def wt_get_table(self, table_name):

        return wowtools.get_table(table_name, self.build)