(cls, name, value)
Block attempts to reassign Enum members.

        A simple assignment to the class namespace only changes one of the
        several possible ways to get an Enum member from the Enum class,
        resulting in an inconsistent Enumeration.
Block attempts to reassign Enum members.
Block attempts to reassign Enum members .
def __setattr__(cls, name, value):
        """
        Block attempts to reassign Enum members.

        A simple assignment to the class namespace only changes one of the
        several possible ways to get an Enum member from the Enum class,
        resulting in an inconsistent Enumeration.
        """
        member_map = cls.__dict__.get('_member_map_', {})
        if name in member_map:
            raise AttributeError('Cannot reassign members.')
        super().__setattr__(name, value)
def __setattr__ ( cls , name , value ) : member_map = cls . __dict__ . get ( '_member_map_' , { } ) if name in member_map : raise AttributeError ( 'Cannot reassign members.' ) super ( ) . __setattr__ ( name , value )