def delete(self, group: Union[(DXFGroup, str)]) -> None:
    ' Delete `group`, `group` can be an object of type :class:`DXFGroup`\n        or a group name as string.\n\n        '
    if isinstance(group, str):
        name = group
    elif (group.dxftype() == 'GROUP'):
        name = get_group_name(group, self.entitydb)
    else:
        raise TypeError(group.dxftype())
    if (name in self):
        super().delete(name)
    else:
        raise const.DXFValueError('GROUP not in group table registered.')
Delete `group`, `group` can be an object of type :class:`DXFGroup`
or a group name as string.
def delete(self, group: Union[(DXFGroup, str)]) -> None:
    ' Delete `group`, `group` can be an object of type :class:`DXFGroup`\n        or a group name as string.\n\n        '
    if isinstance(group, str):
        name = group
    elif (group.dxftype() == 'GROUP'):
        name = get_group_name(group, self.entitydb)
    else:
        raise TypeError(group.dxftype())
    if (name in self):
        super().delete(name)
    else:
        raise const.DXFValueError('GROUP not in group table registered.')