#!/bin/env python
# -*- coding: utf8 -*-

import fedmsg


def message(image_name, dest, status):
    """ Takes an upload destination (ex. "EC2-east") and a status (ex.
    "failed"). Emits a fedmsg appropriate for each image upload task. """

    topic = 'image.upload'

    fedmsg.publish(topic=topic, modname='fedimg', msg={
        'image_name': image_name,
        'destination': dest,
        'status': status,
    })

@@ -50,16 +50,215 @@
 fedmsg%0A%0A
+%22%22%22%0AThe latest Fedmsg meta code for Fedimg fedmsgs (what a mouthful!):%0Ahttps://github.com/fedora-infra/fedmsg_meta_fedora_infrastructure/blob/develop/fedmsg_meta_fedora_infrastructure/fedimg.py%0A%22%22%22%0A%0A
 %0Adef mes
@@ -302,16 +302,31 @@
 %22%22 Takes
+ an image name,
  an uplo
@@ -355,19 +355,29 @@
 C2-e
-ast
+u-west-1
 %22)
+,
  and a
+%0A   
  sta
@@ -384,19 +384,16 @@
 tus (ex.
-%0A  
   %22faile
@@ -445,16 +445,20 @@
 e upload
+%0A   
  task. %22

Improve commenting.