def split_address(address):
    """Split an e-mail address into local part and domain."""
    assert isinstance(address, str), 'address should be of type str'
    if '@' not in address:
        local_part = address
        domain = None
    else:
        local_part, domain = address.rsplit('@', 1)
    return local_part, domain
