verm__ changed the topic of #buildbot to: A Software Freedom Conservancy Project | Buildbot-3.5.0 | docs: http://docs.buildbot.net/current/ | tutorial: http://docs.buildbot.net/current/tutorial | irclogs: https://libera.irclog.whitequark.org/buildbot
LePhilousophe has quit [Ping timeout: 244 seconds]
LePhilousophe has joined #buildbot
wielaard has joined #buildbot
wielaard has quit [Remote host closed the connection]
wielaard has joined #buildbot
mjw has quit [Killed (NickServ (GHOST command used by wielaard!~mjw_@2001:1c06:2488:1400:9e5c:8eff:fe8f:a440))]
wielaard is now known as mjw
mark_ has joined #buildbot
koobs has quit [Ping timeout: 272 seconds]
koobs has joined #buildbot
koobs has quit [Ping timeout: 268 seconds]
LePhilousophe has quit [Ping timeout: 272 seconds]
iomartin has joined #buildbot
iomartin has left #buildbot [#buildbot]
iomartin has joined #buildbot
tgamblin has quit [Ping timeout: 260 seconds]
tgamblin has joined #buildbot
<iomartin> Hello everyone. I'm trying to configure buildbot to run a special builder only on git (annotaged) tags. I'm facing two issues and I'd appreciate help/pointers:
<iomartin> 1. In my workflow, I push a potential revision (still untagged), which triggers a bunch of other tests. When those tests pass, then I create the tag and push. However, since buildbot will already have seen that revision, the build is being ignored.
cognifloyd has joined #buildbot
<iomartin> 2. How can I tell that something is a git tag? Since the ChangeFilter has the revision, I was thinking about trying to somehow do a "git describe --exact-match <revision>" but I don't know a) if this is the best way and b) how to query the git db
<iomartin> Thanks!
tgamblin has quit [Ping timeout: 260 seconds]
<mjw> Interesting question, I don't know the answer, but I would also like to know :)
<mjw> There is buildPushesWithNoCommits=True for gitpoller
<mjw> but I believe that is only for commits already seen on different branches
<iomartin> mjw: this might be useful. Tags are kind of new branches, so it might do the trick. Let me give this a try
<iomartin> Unfortunately that didn't work. If I create a new branch that points to the same revision then the build triggers, but if it's just an annotated tag then it's ignored
<mjw> yeah, I was afraid of that
<mjw> Of course that means that you can use it for new (release) branches
<mjw> which would be somewhat of my use case for this. Trigger a release build on a (signed) annotate tag.
<mjw> but I would really like it if I could use an annotated tag for that (and preferably signed, to do it only for known signatures, but of course that would mean adding some kind of git tag --verify in there somehow)
<iomartin> Yeah, that'd be pretty good. Unfortunately creating a new branch for every release doesn't really match our workflow :(
<iomartin> I almost feel like I'd have to do it via force builds, but then it almost defeats the purpose...
<iomartin> Although that is client-side and thus not so useful...
<iomartin> Or I can have another GitPoller for the same repo and then use `only_tags` for that poller
<mjw> I thought you could only have one poller per repo?
<iomartin> Oh I didn't know about that :(
<iomartin> So I can't replicate everything under a different workdir?
<iomartin> And put it under a different project
<mjw> you might need a different poller dir
<iomartin> Yeah... I'll have to give this a try later today. Thanks
<glogan> iomartin: mjw I think you're looking for something like `ChangeFilter(category='tag_push', branch_re=props['pkg_major_version'] + ".*")`
<glogan> the category changes depending on the host (this is gitlab, github is just 'tag')
<glogan> I'm not 100% sure it won't squash the build since its seen the hash already, but it's worth a shot
<glogan> in our usecase the tag's has is unique :/
<mjw> glogan, how do those set that category? /me isn't using either gitlab or github.
<mjw> Is there a way to set those from a plain git repo?
<glogan> It's in the scheduler, doesn't care what kind of source it's fed
<glogan> although different source -> different category. You may need to do some experimenting
<mjw> glogan, ok, but the poller sets the change source category
<mjw> glogan, how does a gitpoller set the category to indicate the change was a tag setting?
<mjw> is this some special magic only github/gitlab pollers do?
<glogan> ah
<glogan> so mine is hooked up via webhooks, which lets the source (github|lab|whatever) set the category
<glogan> in your case I would define *two* gitpollers. One for general use, another with `only_tags` set to true
<mjw> ok, so you can have two gitpollers for the same repo?
<glogan> at least from the docs, it looks like that should restrict it to *only* generating events on tags. Set that poller's `category` to `tag` or whatever
<glogan> yes
<mjw> I must have misremembered
<glogan> you might need to change the `workdir`
<glogan> since it's going to create a clone for each changesource
<glogan> (which also doubles your storage, but... mhe)
<mjw> That has. Note: There can only be a single GitPoller pointed at any given repository.
<glogan> huh
<mjw> maybe the documentation is wrong, it happens
<glogan> sooo... I wonder how it can tell? It is checkign the URL? In which case can you create two pollers, one with a shorter url, and one with a fqdn? Or ip? :)
<glogan> I struggle to imagine what the issue with having two pollers on the same repo would be, aside from collisions in the workdir
<glogan> I'd give it a try, ignoring the note. Worst case it no worky
<mjw> as far as I understand it (might be wrong/imagining) all pollers put their changes in the same git repo as so pointing two at the same would interfere with each other because they see/overwrite each other changes
<mjw> But maybe the Note means, if you use the same (default) workdir?
<glogan> maybe. The other option is to do this with change hooks. It'd be more dev work on the server side, but it would step around the need for buildbot to have two pollers
iomartin has quit [Quit: Client closed]
LePhilousophe has joined #buildbot
mjw has quit [Killed (NickServ (GHOST command used by mark_!~mark@gnu.wildebeest.org))]
mark_ is now known as mjw
wielaard has joined #buildbot
tgamblin has joined #buildbot