def alert(config, item, known, repo):
    if repo not in known:
        known[repo] = []
    known[repo].append(item.number)
    return requests.post(
        'https://api.mailgun.net/v2/%s/messages' % config['mailgun_domain'],
        auth=('api', config['mailgun_api_key']),
        data={
            'from': config['email_from'],
            'to': config['email_to'],
            'subject': config.get('email_subject', 'ALERT: New GitHub Issue'),
            'text': ('URL: %s\nTitle: %s\nUser: %s' %
                     (item.html_url, item.title, item.user.login))
        }
    )
dataset/ETHPy150Open sivel/github-notify/github-notify.py/alert/original