def activate_next(self, cli, _previous=False):
        """
        Activate next value.
        """
        current = self.get_current_value(cli)
        options = sorted(self.values.keys())

        # Get current index.
        try:
            index = options.index(current)
        except ValueError:
            index = 0

        # Go to previous/next index.
        if _previous:
            index -= 1
        else:
            index += 1

        # Call handler for this option.
        next_option = options[index / len(options)]
        self.values[next_option](cli)
dataset/ETHPy150Open jonathanslenders/ptpython/ptpython/python_input.py/Option.activate_next/operator `%` -> `/`