Microsoft Developer Network > Forums Home > Visual Studio Team System Forums > Microsoft Visual Studio Team Foundation Server 2010 Beta 2 > Build Error when checking in locked files like .dlls when using Gated Check-in
Ask a questionAsk a question
 

Proposed AnswerBuild Error when checking in locked files like .dlls when using Gated Check-in

  • Thursday, November 05, 2009 11:07 PMKidMojo Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Thank you for the Gated Check-in feature!  It's been much requested; however, I have run into a few problems with them in Beta 2.  For one thing, I received a build error dealing that says one of the .dll files I checked in is locked for check-out by me in my workspace.  This occured from the build that gets kicked off from Gated Check-in.  

    Also, why do files have to stay checked out when checking in with gated check-in?  The comment box is not cleared out like normal after check-in even after doing a reconcile. 

    Finally, is there a way to have the gated check-in build not display in the global list so that it doesnt populate the "Integrated In" field?  I already turned off the build option to Associate Changesets and Work Items but that didnt do the trick.

    Thanks!

All Replies

  • Friday, November 06, 2009 12:54 AMCongyi WuMSFTUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Click on the show options arrow thing in the Gated Check-in dialog and tell it to not keep pending changes in your workspace. That should undo the checkouts (after shelving your changes for the gated checkin) and release the checkout lock.
  • Friday, November 06, 2009 2:45 PMMadhuri Gummalla - MSFT Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Proposed Answer

    When you submit a Gated Checkin, the system creates a shelveset of your changes that are then unshevled and built on the build agent before being submitted to Version Control. So if a file has exclusive checkout and it is checked out on your machine, TeamBuild will fail to unshelve it on the build mahcine. By default Version Control has exclusive checkout enabled for binary files, which is the reason your build is failing as the .dll file is checked out exclusively. We know this is a problem but don't have a great solution. Post Beta2 we have a feature to help Build Admin who sets up the gated def to be able to identify if any of the mapped paths is setup for exclusive checkout.  As Congyi suggested you can uncheck the option to "Preserve pending changes in your workspace" to unblock yourself.

    Files staying checked out on the build agent workspace is a bug that has been fixed. Comment box not being cleared on reconcile is also a known bug that will be fixed for RTM.

    The only way to filter the builds from showing up in "Integrated In" field is by creating a BIS Subscription, the same way we could do it in Orcas. Jason Prickett has a blog post on this - http://blogs.msdn.com/jpricket/archive/2006/09/05/how-to-filter-the-build-completion-event.aspx

    Hope this explains.

    Thanks,
    Madhuri

  • Friday, November 06, 2009 4:41 PMKidMojo Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Thank you for the in-depth reply.  I am really enjoying Beta 2 except for a few kinks which hopefully will be worked out. 

    One last question concerning gated check-in:  What is the recommended setting for the option to "Associate Changesets and Work Items" when using gated check-in?  I assume I should not turn this on since our company also uses nightly builds, and I would like the work items associated with the nightly build and not the gated check-in builds. 
  • Friday, November 06, 2009 6:13 PMMadhuri Gummalla - MSFT Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Proposed Answer
    You can turn on "Associated Changesets and Work Items" option for your gated builds. But gated builds will only be associated with one changeset - the changeset that was checked in by the build. Your nightly builds will not be affected as the association of changesets happens per build definition.

    Thanks,
    madhuri