def remove(username, purge=False):
    """
        Remove a user from the workspace, and also unassign from all
        mappings in contained groups (self.groups).

        This does not remove the user from the site, unless all of the
        following conditions are met:

            1. The purge argument is true.
            2. The adaptation context is a top-level project workspace,
            3. The user is not a member of other projects.

            If #1 is true, but either #2 or #3 is False, raises a
            RuntimeError with a message indicating which assertion
            caused a failure.

        Raises ValueError if username specified is not a project member.

        Removal of member from contained workspaces is not in the scope
        of this method, and must be managed by callers.
        """
