微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Buildbot未检测到github存储库中的更改

如何解决Buildbot未检测到github存储库中的更改

这是我使用的buildbot master的master.cfg文件

# -*- python -*-
# ex: set filetype=python:

from buildbot.plugins import *

c = BuildmasterConfig = {}

c['workers'] = [worker.Worker("example-worker","pass"),worker.Worker("example-worker3","pass")]

c['protocols'] = {'pb': {'port': 9989}}


factory = util.BuildFactory()

factory.addStep(steps.Git(repourl='git://github.com/ZanderKraig/Other-testing.git',mode='incremental'))

# factory.addStep(steps.ShellCommand(command=["autopep8","--in-place","--aggressive","run.py"]))

factory.addStep(steps.ShellCommand(command=["Flake8"],env={"PYTHONPATH": "."}))

c['change_source'] = []
c['change_source'].append(changes.GitPoller(repourl="git://github.com/ZanderKraig/Other-testing.git",workdir='gitpoller-workdir',branches=["master"],pollInterval=120,pollAtLaunch=True))

c['schedulers'] = []
c['schedulers'].append(schedulers.ForceScheduler(name="force",builderNames=["echo"]))

quick = schedulers.SingleBranchScheduler(
            name="quick",change_filter=util.ChangeFilter(branch='master'),treeStableTimer=None,builderNames=["echo"])

c['schedulers'].append(quick)
# c['schedulers'].append(schedulers.Periodic(name="minutely",builderNames=["echo"],periodicBuildTimer=60))

# factory.addStep(steps.ShellCommand(command=["git","add","*"]))

# factory.addStep(steps.ShellCommand(command=["git","commit","-m","'Formatted and checked code for errors.'"]))

c['builders'] = []
c['builders'].append(
    util.BuilderConfig(name="echo",workernames=["example-worker","example-worker3"],factory=factory))

c['services'] = []

c['title'] = "Other testing CI"
c['titleURL'] = "https://github.com/ZanderKraig/Other-testing/"

c['buildbotURL'] = "http://localhost:8010/"

c['www'] = dict(port=8010,plugins=dict(waterfall_view={},console_view={},grid_view={}))

c['db'] = {
    # This specifies what database buildbot uses to store its state.
    # It's easy to start with sqlite,but it's recommended to switch to a dedicated
    # database,such as Postgresql or MysqL,for use in production environments.
    # http://docs.buildbot.net/current/manual/configuration/global.html#database-specification
    'db_url': "sqlite:///state.sqlite",}

由于某些原因,Buildbot无法检测到存储库中的更改。我能够运行构建的唯一方法是强制构建或设置周期调度程序(已在上面粘贴的代码中注释掉了)。我已经检查了文档,但是我不明白我在做什么错误。 “ checkconfig”告诉我 config文件很好,因此我没有出现语法错误

详细信息:

Python version: 3.8.3
Buildbot version: 2.8.4
Twisted version: 20.3.0

否则,Buildbot可以正常工作,但是对于持续集成而言,检测源更改至关重要,我需要帮助。

提前谢谢!

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。