<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Mar 10, 2017, at 10:44 AM, Bob Drummond <<a href="mailto:bob.drummond@netronome.com" class="">bob.drummond@netronome.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><pre style="overflow-x:auto;overflow-y:hidden;margin-top:0px;margin-bottom:0px" class="">Have you tried adding properties to the schedulers?<br class=""><br class="">In the source update steps, use <font class="">mode=util.Property("source_mode")<br class=""></font></pre><pre style="overflow-x: auto; overflow-y: hidden; margin-top: 0px; margin-bottom: 0px;" class=""><span class="gmail-n"><br class=""></span></pre>In the force scheduler add this:<pre style="overflow-x:auto;overflow-y:hidden;margin-top:0px;margin-bottom:0px" class=""><span class="gmail-n" style="">properties=[util</span><span class="gmail-o" style="font-weight: bold;">.</span><span class="gmail-n" style="">ChoiceStringParameter</span><span class="gmail-p" style="">(</span><font class="">
</font><span class="gmail-n" style="">name</span><font class=""><span class="gmail-o" style="font-weight:bold">=</span><span class="gmail-s2">"source_mode"</span><span class="gmail-p">,</span>
<span class="gmail-n">choices</span><span class="gmail-o" style="font-weight:bold">=</span><span class="gmail-p">[</span><span class="gmail-s2">"full"</span><span class="gmail-p">,</span> <span class="gmail-s2">"incremental"</span>],</font></pre><pre style="overflow-x:auto;overflow-y:hidden;margin-top:0px;margin-bottom:0px" class=""><font class=""> <span class="gmail-n">default</span><span class="gmail-o" style="font-weight:bold">=</span><span class="gmail-s2">"incremental"</span></font><span class="gmail-p"><font class="">)]</font></span></pre><pre style="overflow-x: auto; overflow-y: hidden; margin-top: 0px; margin-bottom: 0px;" class=""><span class="gmail-p"><br class=""></span></pre><pre style="overflow-x:auto;overflow-y:hidden;margin-top:0px;margin-bottom:0px" class=""><span class="gmail-p">In your current change based scheduler, remember to add <font class="">properties={"source_mode": "incremental"}</font></span>or those builds will fail.</pre></div></div></blockquote><div><br class=""></div><div>That worked great, thanks! In case it's useful to anyone else, here's what I did in addition to the above:</div><div><br class=""></div><div>-- current</div><div><div>macFactory.addStep( steps.Git( repourl=repoURL, branch="master", mode="incremental", alwaysUseLatest=False ) )</div><div class=""><br class=""></div><div class="">-- new</div><div class=""><div class="">macFactory.addStep( steps.Git( repourl=repoURL, branch="master", mode=Property('source_mode'), alwaysUseLatest=False ) )</div></div><div class=""><br class=""></div><div class="">And then add the property to each scheduler with something like:</div><div class=""><br class=""></div><div class="">-- current</div><div class=""><div class="">schedulers.append( SingleBranchScheduler( name="master", branch="master", ... )</div></div><div class=""><br class=""></div><div class="">-- new</div><div class=""><div class="">schedulers.append( SingleBranchScheduler( name="master", branch="master", properties={'source_mode': 'incremental'}, ... )</div></div><div class=""><br class=""></div></div><div>stephen</div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><pre style="overflow-x:auto;overflow-y:hidden;margin-top:0px;margin-bottom:0px" class=""><br class=""></pre><pre style="overflow-x:auto;overflow-y:hidden;margin-top:0px;margin-bottom:0px" class="">I haven't used properties to change the source update mode, but I've used this approach for other things.</pre></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Thu, Mar 9, 2017 at 12:34 PM, Stephen Davis <span dir="ltr" class=""><<a href="mailto:buildbot@soundgeek.org" target="_blank" class="">buildbot@soundgeek.org</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">For speed of commit -> failure turnaround, my builds are configured to use mode="incremental".<br class="">
<br class="">
However, on occasion, some weird build artifact creeps in and the build gets stuck in a bad state. I'd like to configure the Force scheduler to override the "mode" property of the source step so I can force a clean build but I can't figure out how to do it from the docs at <a href="https://docs.buildbot.net/0.8.14/developer/cls-forcesched.html?highlight=force" rel="noreferrer" target="_blank" class="">https://docs.buildbot.net/0.8.<wbr class="">14/developer/cls-forcesched.<wbr class="">html?highlight=force</a>.<br class="">
<br class="">
The current force scheduler config looks like:<br class="">
<br class="">
schedulers.append( ForceScheduler( name = "force",<br class="">
<br class="">
# list of builder names which can be forced<br class="">
builderNames = names,<br class="">
<br class="">
# user specifies the reason<br class="">
reason = StringParameter( name="reason", label="reason:<br>", required=True, size=80 ),<br class="">
<br class="">
# will generate nothing in the form, but revision, repository,<br class="">
# and project are needed by buildbot scheduling system so we<br class="">
# need to pass a value ("")<br class="">
branch = FixedParameter( name="branch", default="" ),<br class="">
revision = FixedParameter( name="revision", default="" ),<br class="">
repository = FixedParameter( name="repository", default="" ),<br class="">
project = FixedParameter( name="project", default="" ),<br class="">
) )<br class="">
<br class="">
What I'd like is to force the source update steps to use "full" or "clobber" mode but that doesn't seem possible. Is there some other option that can be set to force a fresh build on the buildslave?<br class="">
<br class="">
thanks,<br class="">
stephen<br class="">
______________________________<wbr class="">_________________<br class="">
users mailing list<br class="">
<a href="mailto:users@buildbot.net" class="">users@buildbot.net</a><br class="">
<a href="https://lists.buildbot.net/mailman/listinfo/users" rel="noreferrer" target="_blank" class="">https://lists.buildbot.net/<wbr class="">mailman/listinfo/users</a><br class="">
</blockquote></div><br class=""><br clear="all" class=""><div class=""><br class=""></div>-- <br class=""><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><div style="font-family: Helvetica; font-size: 12px; word-wrap: break-word;" class=""><div style="word-wrap:break-word" class=""><div style="word-wrap:break-word" class=""><div style="word-wrap:break-word" class=""><div style="word-wrap:break-word" class=""><b class=""><font color="#002e7a" class="">Bob Drummond</font></b><br class=""><i class=""><font color="#606060" class="">Software Engineer</font></i></div><div style="word-wrap:break-word" class=""><br class=""></div></div></div></div></div><span style="font-family: Helvetica; font-size: 12px;" class=""><div style="word-wrap:break-word" class=""><div style="word-wrap:break-word" class=""><div style="word-wrap:break-word" class=""><font color="#002e7a" class=""><b class="">Netronome</b> </font>| 3159 Unionville Road, Suite 100 Cranberry Twp., PA 16066</div><div style="word-wrap:break-word" class="">Phone: <a href="tel:+1+(724)+778-3295" target="_blank" class="">+1 (724) 778-3295</a> | <a href="http://www.netronome.com/" style="color:rgb(17,85,204)" target="_blank" class="">www.netronome.com</a></div></div></div></span><br style="font-family: Helvetica; font-size: 12px;" class=""><span style="font-family: Helvetica; font-size: 12px;" class=""><span id="cid:833132E0-74CA-446D-B8F0-755E77E3DEB6@netronome.com"><Signature-Option.png></span></span><br class=""></div></div></div></div></div></div></div></div>
</div>
</div></blockquote></div><br class=""></body></html>