[Buildbot-devel] Wrong target url when button 'Force Build' it's pressed.

Brian Warner warner-buildbot at lothar.com
Tue Sep 16 20:00:40 UTC 2008


> See `buildbot.status.web.builder.StatusResourceBuilder.force`:
> 
>         # keep weird stuff out of the branch and revision strings.
> TODO: # centralize this somewhere.
>         if not re.match(r'^[\w\.\-\/]*$', branch):
>             log.msg("bad branch '%s'" % branch)
>             return Redirect("..")
> 
> Among other things, this won't match branch names which include "+".
> I'm only guessing that this is the codepath that the OP is
> encountering, though.

Oh, right, I'd totally forgotten about that. That was to avoid evilness like
shell metacharacters that could transform the checkout command into something
else. If we could audit all the places where branch names get used, we could
possibly remove this (the win32 argv-generation is the biggest problem I know
of). We could certainly relax it to allow + and whatever other non-shellish
characters you'd like.

cheers,
 -Brian




More information about the devel mailing list