From: Eric S. Raymond Date: Mon, 8 Dec 2003 08:36:56 +0000 (+0000) Subject: Minor fixes. X-Git-Tag: 1-1~7 X-Git-Url: http://thyrsus.com/gitweb/?a=commitdiff_plain;h=250163f1e073768005c60d61774c9888a9769856;p=freecode-submit.git Minor fixes. --- diff --git a/freshmeat-submit b/freshmeat-submit index cff893f..a2c7363 100755 --- a/freshmeat-submit +++ b/freshmeat-submit @@ -168,7 +168,9 @@ class FreshmeatMetadataFactory: # Validate and convert the Release-Focus field if "release_focus" in data: val = data["release_focus"].lower() - if val in freshmeat_focus_types: + if val in '123456789': + data["release_focus"] = int(val) + elif val in freshmeat_focus_types: data["release_focus"] = freshmeat_focus_types[val] else: raise FreshmeatSessionException(focus_error) @@ -203,10 +205,10 @@ if __name__ == "__main__": # Log out session.logout() except FreshmeatSessionException, e: - print "meathook:", e.msg + print >>sys.stderr,"meathook:", e.msg sys.exit(1) except xmlrpclib.Fault, f: - print "meathook: %d %s" % (f.faultCode, f.faultString) + print >>sys.stderr,"meathook: %d %s" % (f.faultCode, f.faultString) sys.exit(1) # end