def _get_function(self):
        """
        Returns correct partition function depending on the MySQL column type.
        """
        functions = {
            'date': 'TO_DAYS',
            'datetime': 'TO_DAYS',
            'timestamp': 'UNIX_TIMESTAMP',
        }

        column_type = self._get_column_type()

        try:
            return functions[column_type]
        except __HOLE__:
            raise PartitionFunctionError(
                model=self.model.__name__,
                dialect=self.dialect,
                current=column_type,
                allowed=functions.keys())
dataset/ETHPy150Open maxtepkeev/architect/architect/databases/mysql/partition.py/RangePartition._get_function