Permalink
Browse files

Merging from default\n

changeset:   2942:88d4e6cc2057
parent:      2940:4d5f49af57ab
user:        Rail Aliiev <rail@mozilla.com>
date:        Mon Jan 21 14:39:22 2013 -0500
files:       common.py process/factory.py
description:
Bug 820238 - PuppetAgain config for new Linux64 testing reference platform. r=armenzg


changeset:   2943:c65fd7add8d6
user:        Chris AtLee <catlee@mozilla.com>
date:        Mon Jan 21 19:45:01 2013 -0500
files:       bin/hgpoller.py bin/log_uploader.py bin/postrun.py bin/try_mailer.py bin/update_from_files.py changes/ftppoller.py changes/hgpoller.py changes/mobileftppoller.py changes/tinderboxpoller.py common.py env.py l10n.py log.py misc.py misc_scheduler.py process/factory.py process/release.py scheduler.py status/db/jsoncol.py status/db/model.py status/db/status.py status/errors.py status/generators.py status/log_handlers.py status/mail.py status/pulse.py status/queued_command.py status/tinderboxmailnotifier.py steps/base.py steps/l10n.py steps/misc.py steps/mobile.py steps/mock.py steps/release.py steps/signing.py steps/source.py steps/talos.py steps/test.py steps/unittest.py steps/updates.py test/test_hgpoller.py test/test_misc_important.py test/test_misc_nextslaves.py test/test_misc_scheduler_nightly.py test/test_misc_scheduler_propfuncs.py test/test_misc_scheduler_propscheduler.py test/test_process_factory.py test/test_test_order.py test/test_try_parser.py try_parser.py
description:
nobug: PEP8! r=bitrotallthethings


changeset:   2944:4c7c7df48595
user:        Steve Fink <sfink@mozilla.com>
date:        Tue Jan 22 12:50:07 2013 -0800
files:       misc.py
description:
Bug 830466 - Turn off tipsOnly for try. r=catlee


changeset:   2945:78189628f1e2
tag:         tip
user:        Armen Zambrano Gasparnian <armenzg@mozilla.com>
date:        Tue Jan 22 16:03:32 2013 -0500
files:       misc.py process/factory.py
description:
Bug 710840: Track peak virtual memory usage of link.exe process during libxul
PGO link on graph server. r=bhearsum

--HG--
branch : production-0.8
  • Loading branch information...
2 parents a470055 + 53cbf81 commit 97050edc161868c6bc66a7eee7605ca05a1d171f @kmoir kmoir committed Jan 22, 2013
Showing with 4,659 additions and 3,621 deletions.
  1. +30 −17 bin/hgpoller.py
  2. +70 −47 bin/log_uploader.py
  3. +59 −42 bin/postrun.py
  4. +28 −16 bin/try_mailer.py
  5. +52 −25 bin/update_from_files.py
  6. +23 −18 changes/ftppoller.py
  7. +27 −15 changes/hgpoller.py
  8. +39 −34 changes/mobileftppoller.py
  9. +58 −46 changes/tinderboxpoller.py
  10. +11 −4 common.py
  11. +49 −47 env.py
  12. +20 −13 l10n.py
  13. +10 −2 log.py
  14. +512 −377 misc.py
  15. +49 −34 misc_scheduler.py
  16. +2,141 −1,885 process/factory.py
  17. +278 −227 process/release.py
  18. +51 −33 scheduler.py
  19. +1 −0 status/db/jsoncol.py
  20. +122 −67 status/db/model.py
  21. +50 −26 status/db/status.py
  22. +9 −7 status/errors.py
  23. +1 −2 status/generators.py
  24. +10 −6 status/log_handlers.py
  25. +20 −16 status/mail.py
  26. +31 −28 status/pulse.py
  27. +11 −7 status/queued_command.py
  28. +12 −10 status/tinderboxmailnotifier.py
  29. +7 −3 steps/base.py
  30. +13 −6 steps/l10n.py
  31. +72 −44 steps/misc.py
  32. +11 −8 steps/mobile.py
  33. +18 −17 steps/mock.py
  34. +9 −6 steps/release.py
  35. +3 −3 steps/signing.py
  36. +1 −1 steps/source.py
  37. +21 −13 steps/talos.py
  38. +46 −32 steps/test.py
  39. +92 −58 steps/unittest.py
  40. +16 −13 steps/updates.py
  41. +92 −44 test/test_hgpoller.py
  42. +14 −7 test/test_misc_important.py
  43. +29 −15 test/test_misc_nextslaves.py
  44. +51 −26 test/test_misc_scheduler_nightly.py
  45. +24 −11 test/test_misc_scheduler_propfuncs.py
  46. +12 −5 test/test_misc_scheduler_propscheduler.py
  47. +3 −0 test/test_process_factory.py
  48. +43 −25 test/test_test_order.py
  49. +243 −199 test/test_try_parser.py
  50. +65 −34 try_parser.py
View
@@ -1,16 +1,22 @@
#!/usr/bin/env python
-import urlparse, urllib, time
+import urlparse
+import urllib
+import time
try:
import json
except:
import simplejson as json
-import httplib, urllib2, socket, ssl
+import httplib
+import urllib2
+import socket
+import ssl
import subprocess
from buildbotcustom.changes.hgpoller import _parse_changes
import logging as log
+
def buildValidatingOpener(ca_certs):
class VerifiedHTTPSConnection(httplib.HTTPSConnection):
def connect(self):
@@ -45,6 +51,7 @@ def https_open(self, req):
return url_opener
+
def validating_https_open(url, ca_certs, username=None, password=None):
url_opener = buildValidatingOpener(ca_certs)
req = urllib2.Request(url)
@@ -55,17 +62,18 @@ def validating_https_open(url, ca_certs, username=None, password=None):
req.add_header("Authorization", "Basic %s" % pw)
return url_opener.open(req)
+
def getChanges(base_url, last_changeset=None, tips_only=False, ca_certs=None,
- username=None, password=None):
+ username=None, password=None):
bits = urlparse.urlparse(base_url)
if bits.scheme == 'https':
assert ca_certs, "you must specify ca_certs"
params = [('full', '1')]
if last_changeset:
- params.append( ('fromchange', last_changeset) )
+ params.append(('fromchange', last_changeset))
if tips_only:
- params.append( ('tipsonly', '1') )
+ params.append(('tipsonly', '1'))
url = "%s/json-pushes?%s" % (base_url, urllib.urlencode(params))
log.debug("Fetching %s", url)
@@ -78,22 +86,25 @@ def getChanges(base_url, last_changeset=None, tips_only=False, ca_certs=None,
data = handle.read()
return _parse_changes(data)
+
def sendchange(master, branch, change):
- log.info("Sendchange %s to %s on branch %s", change['changeset'], master, branch)
+ log.info("Sendchange %s to %s on branch %s", change['changeset'],
+ master, branch)
cmd = ['retry.py', '-r', '5', '-s', '5', '-t', '30',
- '--stdout-regexp', 'change sent successfully']
+ '--stdout-regexp', 'change sent successfully']
cmd.extend(
- ['buildbot', 'sendchange',
+ ['buildbot', 'sendchange',
'--master', master,
'--branch', branch,
'--comments', change['comments'].encode('ascii', 'replace'),
'--revision', change['changeset'],
'--user', change['author'].encode('ascii', 'replace'),
'--when', str(change['updated']),
- ])
+ ])
cmd.extend(change['files'])
subprocess.check_call(cmd)
+
def processBranch(branch, state, config):
log.debug("Processing %s", branch)
master = config.get('main', 'master')
@@ -116,13 +127,14 @@ def processBranch(branch, state, config):
try:
changes = getChanges(url, tips_only=tips_only,
- last_changeset=last_changeset, ca_certs=ca_certs,
- username=username, password=password)
+ last_changeset=last_changeset, ca_certs=ca_certs,
+ username=username, password=password)
# Do sendchanges!
for c in changes:
# Ignore off-default branches
if c['branch'] != 'default' and config.getboolean(branch, 'default_branch_only'):
- log.info("Skipping %s on branch %s", c['changeset'], c['branch'])
+ log.info(
+ "Skipping %s on branch %s", c['changeset'], c['branch'])
continue
# Change the comments to include the url to the revision
c['comments'] += ' %s/rev/%s' % (url, c['changeset'])
@@ -150,11 +162,12 @@ def processBranch(branch, state, config):
parser = OptionParser()
parser.set_defaults(
- config_file="hgpoller.ini",
- verbosity=log.INFO,
- )
+ config_file="hgpoller.ini",
+ verbosity=log.INFO,
+ )
parser.add_option("-f", "--config-file", dest="config_file")
- parser.add_option("-v", "--verbose", dest="verbosity", action="store_const", const=log.DEBUG)
+ parser.add_option("-v", "--verbose", dest="verbosity",
+ action="store_const", const=log.DEBUG)
options, args = parser.parse_args()
@@ -168,7 +181,7 @@ def processBranch(branch, state, config):
'interval': 300,
'state_file': 'state.json',
'default_branch_only': "yes",
- })
+ })
config.read(options.config_file)
try:
Oops, something went wrong.

0 comments on commit 97050ed

Please sign in to comment.