class at_time:
    actions = {}

    def __init__(self, time_of_day):
        self.time_of_day = time_of_day

    def __call__(self, func):
        self.actions.setdefault(func.__qualname__, {})[self.time_of_day] = func
        return self

    def __set_name__(self, owner, name):
        self.name = name
        for time_of_day, func in self.actions.pop(
                '.'.join((owner.__qualname__, name))).items():
            setattr(owner, f'_{name}_{time_of_day}', func)

    def __get__(self, obj, objtype):
        def wrapper(time_of_day):
            try:
                return getattr(obj, f'_{self.name}_{time_of_day}')()
            except AttributeError:
                raise ValueError(f'No {self.name} found in the {time_of_day} time')
        return wrapper

class PersonalChef():
    @at_time('morning')
    def cook(self):
        print("Cooking breakfast")

    @at_time('evening')
    def cook(self):
        print("Cooking dinner")

class PersonalChefUK(PersonalChef):
    @at_time('evening')
    def cook(self):
        print("Cooking supper")

PersonalChef().cook('morning')
PersonalChef().cook('evening')
PersonalChefUK().cook('morning')
PersonalChefUK().cook('evening')