title: TFS2015: gated check-in build locking files
body: <p>I'm trying to setup a gated check-in build (vNext) on a TFS2015.3 server.
  After I check-in a modification the build is triggered. The build runs smooth but the modified files are remaining locked by Project Collection Build Service (TEAM FOUNDATION).</p>
  
  <p>From the build logs I can see that the "Check in gated changes" step is performed correctly.</p>
  
  <p>If the team project source control has the multiple check-out option disable I'm not able to modify the locked files unless I unlock them or we queue the build again.</p>
  
  <p>Any idea how to determine the gated check-in build to unlock the files at the end?</p>
  
  <p><strong>Update</strong></p>
  
  <p>After more tests I've found that the gated check-in build is releasing the files on a newly created collection; the locking issue is happening on a collection upgraded from TFS2012.</p>
  
  <p><strong>Update 2</strong></p>
  
  <p>Manually running again (after a gated check-in) the build cause the files to be unlocked:</p>
  
  <blockquote>
    <p>Undo any pending changes under workspace.</p>
    
    <p>tf undo Undoing edit:</p>
    
    <p>D:\B\2\3\s\ConsoleApplication1\Program.cs</p>
  </blockquote>