You will need the following development packages:
- zlib-devel (zlib1g-dev)
- bzip2-devel (libbz2-dev)
In a directory containing the buildout.cfg and bootstrap.py from this gist:
from buildbot.status.web.waterfall import WaterfallStatusResource | |
from buildbot.status.web.baseweb import WebStatus | |
class MyWebStatus(WebStatus): | |
def setupUsualPages(self, numbuilds, num_events, num_events_max): | |
self.setupUsualPages(numbuilds, num_events, num_events_max) | |
self.putChild("waterfall", WaterfallStatusResource( |
class RecurseLock(object): | |
""" | |
Maintain a stack of settings referenced by LazierSetting so we can trap recursion. | |
We use a context manager to surround variable access, and ensure that the stack is cleared. | |
Error message contains a stack trace:: | |
Setting FOO was used recursively | |
FOO -> BAR -> BAZ -> FOO |
############################################################################## | |
# | |
# Copyright (c) 2006 Zope Foundation and Contributors. | |
# All Rights Reserved. | |
# | |
# This software is subject to the provisions of the Zope Public License, | |
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. | |
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED | |
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | |
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS |
class LastBuild(util.ComparableMixin): | |
""" | |
This code isn't meant to be functional! | |
It's really pseudo code for how i would the # of the last successful | |
build into a completely unrelated build - some digging around will | |
be required. | |
You are invited to explore the build.master API and see if there is | |
a better way to iterate previous builds - look for getLastFinishedBuild. |
class Unauthorized(Exception): | |
def __init__(self, code): | |
self.code = code | |
class BaseAdaptor(object): | |
retries = 10 | |
adapts = None |
import os, shlex | |
from twisted.internet import defer, utils, reactor, threads | |
from twisted.python import log, failure | |
from buildbot.buildslave import AbstractBuildSlave, AbstractLatentBuildSlave | |
from buildbot import config | |
class ScriptedLatedBuildSlave(AbstractLatentBuildSlave): |
from buildbot.status.web.waterfall import WaterfallStatusResource | |
from buildbot.status.web.baseweb import WebStatus | |
class MyWebStatus(WebStatus): | |
def setupUsualPages(self, numbuilds, num_events, num_events_max): | |
self.setupUsualPages(numbuilds, num_events, num_events_max) | |
self.putChild("waterfalls", WaterfallsResource( | |
num_events=num_events, |
def _setBuildWaitTimer(self): | |
self._clearBuildWaitTimer() | |
if self.build_wait_timeout <= 0: | |
return | |
self.build_wait_timer = reactor.callLater( | |
self.build_wait_timeout, self._soft_disconnect) |
@defer.inlineCallbacks | |
def _soft_disconnect(self, fast=False): | |
if not self.build_wait_timeout < 0: | |
yield AbstractBuildSlave.disconnect(self) | |
return | |
if self.missing_timer: | |
self.missing_timer.cancel() | |
self.missing_timer = None |