[Buildbot-commits] [Buildbot] #2075: BaseScheduler.__init__ builderNames must be str objects even though documentation says 'unicode list'

Buildbot nobody at buildbot.net
Tue Aug 9 17:18:31 UTC 2011


#2075: BaseScheduler.__init__ builderNames must be str objects even though
documentation says 'unicode list'
----------------------------+-----------------------
Reporter:  eric@…           |      Owner:
    Type:  defect           |     Status:  new
Priority:  minor            |  Milestone:  undecided
 Version:  0.8.4p2          |   Keywords:
----------------------------+-----------------------
 http://buildbot.net/buildbot/docs/0.8.4p2/reference/buildbot.schedulers.base
 .BaseScheduler-class.html

 builderNames (list of unicode) - list of builders this scheduler may start

 https://github.com/buildbot/buildbot/blob/master/master/buildbot/schedulers/base.py#L67


 I'm writing a test harness for WebKit's buildbot master config and using a
 newer version of simplejson than I think buildbot expects.  simplejson is
 returning unicode strings to me, which I'm passing to a scheduler and
 hitting this assert:


 {'change_filter': <ChangeFilter on branch in ['trunk', None]>,
 'builderNames': [u'GTK Linux 32-bit Release', u'GTK Linux 32-bit Debug',
 u'GTK Linux 64-bit Debug', u'Qt Linux Release', u'Qt Linux Release
 minimal', u'Qt Linux ARMv7 Release', u'Qt Windows 32-bit Release', u'Qt
 Windows 32-bit Debug', u'Qt Linux MIPS Release', u'Chromium Win Release',
 u'Chromium Win Release (Tests)', u'Chromium Mac Release', u'Chromium Mac
 Release (Tests)', u'Chromium Linux Release', u'Chromium Linux Release
 (Tests)', u'Chromium Linux Release (Flexbox)', u'WinCairo Debug (Build)',
 u'WinCE Release (Build)', u'EFL Linux Release (Build)'], 'name': u'trunk',
 'treeStableTimer': 45.0}
 Traceback (most recent call last):
   File "test.py", line 63, in <module>
     execfile('master.cfg')
   File "master.cfg", line 758, in <module>
     loadBuilderConfig(c)
   File "master.cfg", line 724, in loadBuilderConfig
     c['schedulers'].append(kls(**scheduler))
   File
 "/Projects/WebKit/Tools/Scripts/webkitpy/thirdparty/autoinstalled/buildbot/schedulers/basic.py",
 line 229, in __init__
     SingleBranchScheduler.__init__(self, *args, **kwargs)
   File
 "/Projects/WebKit/Tools/Scripts/webkitpy/thirdparty/autoinstalled/buildbot/schedulers/basic.py",
 line 41, in __init__
     base.BaseScheduler.__init__(self, name, builderNames, properties)
   File
 "/Projects/WebKit/Tools/Scripts/webkitpy/thirdparty/autoinstalled/buildbot/schedulers/base.py",
 line 68, in __init__
     assert isinstance(b, str), errmsg
 AssertionError: The builderNames argument to a scheduler must be a list of
 Builder names.


 I'll fix my code to work around this, but it seems either the buildbot
 docs should be changed, or better yet, BaseScheduler should be fixed to
 allow unicode buildernames.

-- 
Ticket URL: <http://trac.buildbot.net/ticket/2075>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation


More information about the Commits mailing list