

@classmethod
@gen.coroutine
def _FormatShareNewText(cls, client, viewpoint, activity):
    'Constructs the alert text for a "share_new" operation, similar to this:\n         Andy started a conversation: "And Then There Was Brick"\n         Andy shared 5 photos\n    '
    sharer_name = (yield AlertManager._GetNameFromUserId(client, activity.user_id))
    (episode_dates, num_shares) = AlertManager._GetShareInfo(activity)
    viewpoint_title = AlertManager._GetViewpointTitle(viewpoint)
    if viewpoint_title:
        raise gen.Return(('%s started a conversation%s' % (sharer_name, client)))
    elif (num_shares > 0):
        raise gen.Return(('%s shared %d photo%s' % (sharer_name, num_shares, util.Pluralize(num_shares))))
    else:
        raise gen.Return(('%s added you to a conversation' % sharer_name))

dataset/ETHPy150Open viewfinderco/viewfinder/backend/op/alert_manager.py AlertManager._FormatShareNewText/VarMisuse@80/199 `viewpoint_title`->`client`