def __init__(self, status, include_only_cq_trybots=False): JsonResource.__init__(self, status) for builder_name in self.status.getBuilderNames(): if builder_name_schema.IsTrybot(builder_name) and ( not include_only_cq_trybots or builder_name in slaves_cfg.CQ_TRYBOTS): self.putChild(builder_name, BuilderJsonResource(status, status.getBuilder(builder_name)))
def __init__(self, status, user): JsonResource.__init__(self, status) for component in misc.COMPONENTS: parts = component.partition('/') if parts[0] != user: continue log.msg("Adding %s as a child component of %s" % (component, user)) self.putChild(parts[2], ComponentJsonResource(status, component))
def __init__(self, status, order_by_time=False): JsonResource.__init__(self, status) self.cache = CacheStatus() if order_by_time: self.comparator = TimeRevisionComparator() else: self.comparator = IntegerRevisionComparator()
def __init__(self, status, include_only_cq_trybots=False): JsonResource.__init__(self, status) for builder_name in self.status.getBuilderNames(): if builder_name_schema.IsTrybot(builder_name) and ( not include_only_cq_trybots or builder_name in slaves_cfg.CQ_TRYBOTS): self.putChild( builder_name, BuilderJsonResource(status, status.getBuilder(builder_name)))
def JsonStatusResourceInit(self, status): """ Override of buildbot.status.web.status_json.JsonStatusResource.__init__: http://src.chromium.org/viewvc/chrome/trunk/tools/build/third_party/buildbot_8_4p1/buildbot/status/web/status_json.py?view=markup We add trybots, cqtrybots, cq_required_steps (details below). """ JsonResource.__init__(self, status) self.level = 1 self.putChild('builders', BuildersJsonResource(status)) self.putChild('change_sources', ChangeSourcesJsonResource(status)) self.putChild('project', ProjectJsonResource(status)) self.putChild('slaves', SlavesJsonResource(status)) self.putChild('metrics', MetricsJsonResource(status)) ############################## Added by borenet ############################## # Added to address: https://code.google.com/p/skia/issues/detail?id=1134 self.putChild('trybots', TryBuildersJsonResource(status)) ############################################################################## ############################## Added by rmistry ############################## # Added to have a place to get the list of trybots run by the CQ. self.putChild( 'cqtrybots', TryBuildersJsonResource(status, include_only_cq_trybots=True)) ############################################################################## ############################## Added by borenet ############################## # Added to have a place to get the list of steps which cannot fail on the CQ. self.putChild('cq_required_steps', CQRequiredStepsJsonResource(status)) ############################################################################## ############################## Added by borenet ############################## # Added to have a way to determine which code revision the master is running. self.putChild('master_revision', master_revision.MasterCheckedOutRevisionJsonResource(status)) running_rev = config_private.Master.get_active_master().running_revision self.putChild( 'master_running_revision', master_revision.MasterRunningRevisionJsonResource( status=status, running_revision=running_rev)) # This page gives the result of the most recent build for each builder. self.putChild('builder_statuses', builder_statuses.BuilderStatusesJsonResource(status)) ############################################################################## # This needs to be called before the first HelpResource().body call. self.hackExamples()
def JsonStatusResourceInit(self, status): """ Override of buildbot.status.web.status_json.JsonStatusResource.__init__: http://src.chromium.org/viewvc/chrome/trunk/tools/build/third_party/buildbot_8_4p1/buildbot/status/web/status_json.py?view=markup We add trybots, cqtrybots, cq_required_steps (details below). """ JsonResource.__init__(self, status) self.level = 1 self.putChild('builders', BuildersJsonResource(status)) self.putChild('change_sources', ChangeSourcesJsonResource(status)) self.putChild('project', ProjectJsonResource(status)) self.putChild('slaves', SlavesJsonResource(status)) self.putChild('metrics', MetricsJsonResource(status)) ############################## Added by borenet ############################## # Added to address: https://code.google.com/p/skia/issues/detail?id=1134 self.putChild('trybots', TryBuildersJsonResource(status)) ############################################################################## ############################## Added by rmistry ############################## # Added to have a place to get the list of trybots run by the CQ. self.putChild('cqtrybots', TryBuildersJsonResource(status, include_only_cq_trybots=True)) ############################################################################## ############################## Added by borenet ############################## # Added to have a place to get the list of steps which cannot fail on the CQ. self.putChild('cq_required_steps', CQRequiredStepsJsonResource(status)) ############################################################################## ############################## Added by borenet ############################## # Added to have a way to determine which code revision the master is running. self.putChild('master_revision', master_revision.MasterCheckedOutRevisionJsonResource(status)) running_rev = config_private.Master.get_active_master().running_revision self.putChild('master_running_revision', master_revision.MasterRunningRevisionJsonResource( status=status, running_revision=running_rev)) # This page gives the result of the most recent build for each builder. self.putChild('builder_statuses', builder_statuses.BuilderStatusesJsonResource(status)) ############################################################################## # This needs to be called before the first HelpResource().body call. self.hackExamples()
def __init__(self, status, project): JsonResource.__init__(self, status) self._project = project
def __init__(self, status): JsonResource.__init__(self, status) users = [component.partition('/')[0] for component in misc.COMPONENTS] for user in set(users): log.msg("Adding %s as a user component" % (user, )) self.putChild(user, ComponentUserJsonResource(status, user))
def __init__(self, running_revision, **kwargs): JsonResource.__init__(self, **kwargs) self._running_revision = running_revision