bug 811293: one-off partner repacks should sign with the signing server instead of by hand - write with sys.stdout.write instead of print so that we don't get newlines in the token.
authorBen Hearsum <bhearsum@mozilla.com>
Thu, 06 Dec 2012 08:47:22 -0500
changeset 3257 2dc15e3ec0caf8f677644a568796663a9726186a
parent 3256 557f7c6740d496d542e66675201d7b5815847b9e
child 3258 411c1748b9bb1f78492559a0463a04a71c368661
push id2319
push userbhearsum@mozilla.com
push dateThu, 06 Dec 2012 13:48:06 +0000
bugs811293
bug 811293: one-off partner repacks should sign with the signing server instead of by hand - write with sys.stdout.write instead of print so that we don't get newlines in the token.
release/signing/get_token.py
--- a/release/signing/get_token.py
+++ b/release/signing/get_token.py
@@ -1,10 +1,11 @@
 import os
 import site
+import sys
 
 my_dir = os.path.dirname(__file__)
 site.addsitedir(os.path.join(my_dir, '../../lib/python'))
 
 from signing.client import buildValidatingOpener, get_token
 
 if __name__ == '__main__':
     from optparse import OptionParser
@@ -15,9 +16,9 @@ if __name__ == '__main__':
     parser.add_option('-p', '--password', dest='password')
     parser.add_option('-H', '--host', dest='host')
     parser.add_option('-d', '--duration', dest='duration')
     parser.add_option('-i', '--ip', dest='slave_ip')
     options, args = parser.parse_args()
 
     buildValidatingOpener(options.cert)
     baseurl = 'https://%s' % options.host
-    print get_token(baseurl, options.username, options.password, options.slave_ip, options.duration)
+    sys.stdout.write(get_token(baseurl, options.username, options.password, options.slave_ip, options.duration))