huserben / TfsExtensions

Extensions for TFS 2015+ such as custom Widgets (require TFS 2017) and Build Tasks
MIT License
44 stars 22 forks source link

[TFS2015] Trigger build don't use branch passed #162

Closed HayaTomAs closed 3 years ago

HayaTomAs commented 3 years ago

Hello, Thanks for the tool.

I'm having trouble, the trigger build still use default branch.

TFS : Version 14.114.27412.0 Agent : 1.95.4 (AgentTFS2015-U41) Version Trigger : 2.9.2

TFS build interface: 2021-02-10_08h58_24

TFS logs begining : 2021-02-09T01:08:49.7926905Z Checking if artifacts directory exists: C:\TfsData\buildcascade_work\19\a 2021-02-09T01:08:49.7926905Z Deleting artifacts directory. 2021-02-09T01:08:49.8082907Z Creating artifacts directory. 2021-02-09T01:08:49.8082907Z Checking if test results directory exists: C:\TfsData\buildcascade_work\19\TestResults 2021-02-09T01:08:49.8082907Z Deleting test results directory. 2021-02-09T01:08:49.8082907Z Creating test results directory. 2021-02-09T01:08:49.8394911Z Démarrage : Obtenir les sources 2021-02-09T01:08:49.8394911Z Entering TfvcSourceProvider.PrepareRepositoryAsync 2021-02-09T01:08:49.8550913Z localPath=C:\TfsData\buildcascade_work\19\s 2021-02-09T01:08:49.8550913Z clean=False 2021-02-09T01:08:49.8550913Z sourceVersion=10692 2021-02-09T01:08:49.8550913Z mappingJson={"mappings":[{"serverPath":"$/Cassiopee-Application/tma","mappingType":"map","localPath":"\"}]} 2021-02-09T01:08:49.8550913Z Syncing repository: Cassiopee-Application (TFVC) 2021-02-09T01:08:49.8550913Z workspaceName=ws_19_5 2021-02-09T01:08:54.5351513Z Nom de l'espace de travail : ws_19_5;Build\3d8b5640-1a02-46f7-a408-0a710daf1be1 2021-02-09T01:08:54.6443527Z tf get /version:10692 2021-02-09T01:08:54.9875571Z Done syncing repository Cassiopee-Application to version 10692 (workspace version C10692) 2021-02-09T01:08:54.9875571Z Leaving TfvcSourceProvider.PrepareRepositoryAsync 2021-02-09T01:08:55.1123587Z Tâches en cours d'exécution

Trigger debug log : 2021-02-09T01:08:46.5478489Z ##[debug]agent.TempDirectory=undefined 2021-02-09T01:08:46.5478489Z ##[debug]agent.workFolder=C:\TfsData\build_work 2021-02-09T01:08:46.5478489Z ##[debug]loading inputs and endpoints 2021-02-09T01:08:46.5478489Z ##[debug]loading ENDPOINTAUTH$/ 2021-02-09T01:08:46.5478489Z ##[debug]loading ENDPOINT_AUTH_SYSTEMVSSCONNECTION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_AUTHENTICATIONMETHOD 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_BLOCKINPROGRESSBUILDS 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_BUILDDEFINITION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_BUILDPARAMETERS 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_CANCELBUILDSIFANYFAILS 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_DEFINITIONISINCURRENTTEAMPROJECT 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_DEPENDENTONFAILEDBUILDCONDITION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_DEPENDENTONSUCCESSFULBUILDCONDITION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_DOWNLOADBUILDARTIFACTS 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_DROPDIRECTORY 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_ENABLEBUILDINQUEUECONDITION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_FAILTASKIFBUILDSNOTSUCCESSFUL 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_FAILTASKIFCONDITIONSARENOTFULFILLED 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_IGNORESSLCERTIFICATEERRORS 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_INCLUDECURRENTBUILDDEFINITION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_PASSWORD 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_QUEUEBUILDFORUSERTHATTRIGGEREDBUILD 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_STOREINENVIRONMENTVARIABLE 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_TREATPARTIALLYSUCCEEDEDBUILDASSUCCESSFUL 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_USESAMEBRANCH 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_USESAMESOURCEVERSION 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_WAITFORQUEUEDBUILDSTOFINISH 2021-02-09T01:08:46.5478489Z ##[debug]loading INPUT_WAITFORQUEUEDBUILDSTOFINISHREFRESHTIME 2021-02-09T01:08:46.5478489Z ##[debug]loaded 25 2021-02-09T01:08:46.5478489Z ##[debug]Agent.ProxyUrl=undefined 2021-02-09T01:08:46.5634491Z ##[debug]Agent.CAInfo=undefined 2021-02-09T01:08:46.5634491Z ##[debug]Agent.ClientCert=undefined 2021-02-09T01:08:46.5634491Z ##[debug]Agent.SkipCertValidation=undefined 2021-02-09T01:08:46.5634491Z ##[debug]definitionIsInCurrentTeamProject=true 2021-02-09T01:08:46.5634491Z ##[debug]tfsServer=null 2021-02-09T01:08:46.5790493Z ##[debug]buildDefinition=WebService ISant├® 2021-02-09T01:08:46.5790493Z ##[debug]ignoreSslCertificateErrors=false 2021-02-09T01:08:46.5790493Z ##[debug]queueBuildForUserThatTriggeredBuild=true 2021-02-09T01:08:46.5790493Z ##[debug]useSameSourceVersion=false 2021-02-09T01:08:46.5946495Z ##[debug]useSameBranch=true 2021-02-09T01:08:46.5946495Z ##[debug]branchToUse=null 2021-02-09T01:08:46.5946495Z ##[debug]waitForQueuedBuildsToFinish=true 2021-02-09T01:08:46.5946495Z ##[debug]waitForQueuedBuildsToFinishRefreshTime=60 2021-02-09T01:08:46.5946495Z ##[debug]failTaskIfBuildsNotSuccessful=true 2021-02-09T01:08:46.5946495Z ##[debug]cancelBuildsIfAnyFails=false 2021-02-09T01:08:46.5946495Z ##[debug]treatPartiallySucceededBuildAsSuccessful=false 2021-02-09T01:08:46.5946495Z ##[debug]downloadBuildArtifacts=false 2021-02-09T01:08:46.5946495Z ##[debug]dropDirectory=C:\TfsData\build_work 2021-02-09T01:08:46.5946495Z ##[debug]storeInEnvironmentVariable=false 2021-02-09T01:08:46.5946495Z ##[debug]demands=null 2021-02-09T01:08:46.5946495Z ##[debug]queueid=null 2021-02-09T01:08:46.5946495Z ##[debug]buildParameters=serveurDeploiement:smi-ws-prod 2021-02-09T01:08:46.5946495Z ##[debug]authenticationMethod=OAuth Token 2021-02-09T01:08:46.5946495Z ##[debug]username=null 2021-02-09T01:08:46.5946495Z ##[debug]password=**** 2021-02-09T01:08:46.5946495Z ##[debug]enableBuildInQueueCondition=false 2021-02-09T01:08:46.5946495Z ##[debug]includeCurrentBuildDefinition=true 2021-02-09T01:08:46.5946495Z ##[debug]blockingBuildsList=null 2021-02-09T01:08:46.5946495Z ##[debug]blockInProgressBuilds=false 2021-02-09T01:08:46.5946495Z ##[debug]dependentOnSuccessfulBuildCondition=false 2021-02-09T01:08:46.5946495Z ##[debug]dependentBuildsList=null 2021-02-09T01:08:46.5946495Z ##[debug]dependentOnFailedBuildCondition=false 2021-02-09T01:08:46.5946495Z ##[debug]dependentFailingBuildsList=null 2021-02-09T01:08:46.5946495Z ##[debug]failTaskIfConditionsAreNotFulfilled=false 2021-02-09T01:08:46.5946495Z Using current Team Project Url 2021-02-09T01:08:46.5946495Z Path to Server: http://TFSServer/tfs/SMIDevCollection/Cassiopee-Application 2021-02-09T01:08:46.5946495Z Using OAuth Access Token 2021-02-09T01:08:46.5946495Z Build shall be triggered for same user that triggered current build: [SMIDevCollection]\Comptes de service de la collection de projets 2021-02-09T01:08:46.5946495Z Using same branch as source version: $/Cassiopee-Application/Main 2021-02-09T01:08:46.5946495Z Will trigger build with following parameters: serveurDeploiement:smi-ws-prod 2021-02-09T01:08:46.5946495Z ##[debug]Sending Request to following url: 2021-02-09T01:08:46.5946495Z ##[debug]build/definitions?api-version=2.0&name=WebService%20ISant%C3%A9 2021-02-09T01:08:46.6258499Z ##[debug]Result: 2021-02-09T01:08:46.6414501Z ##[debug]{"count":1,"value":[{"quality":"definition","authoredBy":{"id":"3f115990-5d34-4b92-b751-83f5e3301117","displayName":"Thomas","uniqueName":"DOMAIN\user","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/3f115990-5d34-4b92-b751-83f5e3301117","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=3f115990-5d34-4b92-b751-83f5e3301117"},"queue":{"pool":{"id":1,"name":"Default"},"id":1,"name":"Default"},"uri":"vstfs:///Build/Definition/100","type":"build","revision":15,"id":100,"name":"WebService ISant├®","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Definitions/100","project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29}}]} 2021-02-09T01:08:46.6570503Z Found parameter serveurDeploiement with value: smi-ws-prod 2021-02-09T01:08:46.6570503Z Queue new Build for definition WebService ISant├® 2021-02-09T01:08:46.6570503Z ##[debug]Sending Request to following url: 2021-02-09T01:08:46.6570503Z ##[debug]build/builds?api-version=2.0&ignoreWarnings=true 2021-02-09T01:08:46.6570503Z ##[debug]Request Body: {"definition":{"id":100},"sourceBranch":"$/Cassiopee-Application/Main","requestedFor":{"id":"8fbe6566-40a1-4f76-a7e5-1e04acb804e8"}, "parameters": "{\"serveurDeploiement\": \"smi-ws-prod\"}"} 2021-02-09T01:08:46.9846545Z ##[debug]Result 2021-02-09T01:08:46.9846545Z ##[debug]{"request":{"uri":{"protocol":"http:","slashes":true,"auth":null,"host":"TFSServer","port":"8080","hostname":"smi-tfs01","hash":null,"search":"?api-version=2.0&ignoreWarnings=true","query":"api-version=2.0&ignoreWarnings=true","pathname":"/tfs/SMIDevCollection/Cassiopee-Application/_apis/build/builds","path":"/tfs/SMIDevCollection/Cassiopee-Application/_apis/build/builds?api-version=2.0&ignoreWarnings=true","href":"http://TFSServer/tfs/SMIDevCollection/Cassiopee-Application/_apis/build/builds?api-version=2.0&ignoreWarnings=true"},"method":"POST","headers":{"Content-Type":"application/json","authorization":"Bearer ****","content-length":191}},"message":{"statusCode":200,"body":"{\"_links\":{\"self\":{\"href\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297\"},\"web\":{\"href\":\"http://TFSServer/tfs/_permalink/_build/index?collectionId=3d8b5640-1a02-46f7-a408-0a710daf1be1&projectId=c15b83b5-0351-4c1e-abfb-82195dc28860&buildId=11297\"},\"timeline\":{\"href\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/Timeline\"}},\"properties\":{},\"id\":11297,\"buildNumber\":\"11297\",\"status\":\"notStarted\",\"queueTime\":\"2021-02-09T01:08:46.6414501Z\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297\",\"definition\":{\"type\":\"build\",\"revision\":15,\"id\":100,\"name\":\"WebService ISant├®\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Definitions/100\",\"project\":{\"id\":\"c15b83b5-0351-4c1e-abfb-82195dc28860\",\"name\":\"Cassiopee-Application\",\"description\":\"Projet de d├®veloppement de l'application de gestion Cassiop├®e\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860\",\"state\":\"wellFormed\",\"revision\":29}},\"project\":{\"id\":\"c15b83b5-0351-4c1e-abfb-82195dc28860\",\"name\":\"Cassiopee-Application\",\"description\":\"Projet de d├®veloppement de l'application de gestion Cassiop├®e\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860\",\"state\":\"wellFormed\",\"revision\":29},\"uri\":\"vstfs:///Build/Build/11297\",\"sourceBranch\":\"$/Cassiopee-Application/Main\",\"queue\":{\"pool\":{\"id\":1,\"name\":\"Default\"},\"id\":1,\"name\":\"Default\"},\"priority\":\"normal\",\"reason\":\"manual\",\"requestedFor\":{\"id\":\"8fbe6566-40a1-4f76-a7e5-1e04acb804e8\",\"displayName\":\"[SMIDevCollection]\\\\Comptes de service de la collection de projets\",\"uniqueName\":\"vstfs:///Framework/IdentityDomain/3d8b5640-1a02-46f7-a408-0a710daf1be1\\Comptes de service de la collection de projets\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/8fbe6566-40a1-4f76-a7e5-1e04acb804e8\",\"imageUrl\":\"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=8fbe6566-40a1-4f76-a7e5-1e04acb804e8\",\"isContainer\":true},\"requestedBy\":{\"id\":\"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"displayName\":\"Service de build de collection de projets\",\"uniqueName\":\"Build\\3d8b5640-1a02-46f7-a408-0a710daf1be1\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"imageUrl\":\"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\"},\"lastChangedDate\":\"2021-02-09T01:08:46.8Z\",\"lastChangedBy\":{\"id\":\"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"displayName\":\"Service de build de collection de projets\",\"uniqueName\":\"Build\\3d8b5640-1a02-46f7-a408-0a710daf1be1\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"imageUrl\":\"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\"},\"parameters\":\"{\\\"serveurDeploiement\\": \\"smi-ws-prod\\"}\",\"orchestrationPlan\":{\"planId\":\"e0a9c5cd-6c75-478b-bbc3-2a218b2a9e95\"},\"logs\":{\"id\":0,\"type\":\"Container\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/logs\"},\"repository\":{\"id\":\"$/\",\"type\":\"TfsVersionControl\",\"clean\":null,\"checkoutSubmodules\":false},\"keepForever\":false}","headers":{"cache-control":"no-cache","pragma":"no-cache","content-type":"application/json; charset=utf-8; api-version=2.0","expires":"-1","server":"Microsoft-IIS/7.5","x-tfs-processid":"87a24173-fcda-4ff9-b8a0-f8de7c62d0e4","access-control-allow-origin":"*","access-control-max-age":"3600","access-control-allow-methods":"OPTIONS,GET,POST,PATCH,PUT,DELETE","access-control-expose-headers":"ActivityId,X-TFS-Session,X-MS-ContinuationToken","access-control-allow-headers":"authorization","x-frame-options":"SAMEORIGIN","set-cookie":["Tfs-SessionId=4cee7711-fa05-4677-ade2-87530503eb7e; path=/","Tfs-SessionActive=2021-02-09 01:08:46Z; path=/"],"x-vss-userdata":"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe:3d8b5640-1a02-46f7-a408-0a710daf1be1","activityid":"4cee7711-fa05-4677-ade2-87530503eb7e","x-tfs-session":"4cee7711-fa05-4677-ade2-87530503eb7e","x-aspnet-version":"4.0.30319","x-powered-by":"ASP.NET","p3p":"CP=\"CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT\"","x-content-type-options":"nosniff","date":"Tue, 09 Feb 2021 01:08:46 GMT","connection":"close","content-length":"3441"},"request":{"uri":{"protocol":"http:","slashes":true,"auth":null,"host":"TFSServer","port":"8080","hostname":"smi-tfs01","hash":null,"search":"?api-version=2.0&ignoreWarnings=true","query":"api-version=2.0&ignoreWarnings=true","pathname":"/tfs/SMIDevCollection/Cassiopee-Application/_apis/build/builds","path":"/tfs/SMIDevCollection/Cassiopee-Application/_apis/build/builds?api-version=2.0&ignoreWarnings=true","href":"http://TFSServer/tfs/SMIDevCollection/Cassiopee-Application/_apis/build/builds?api-version=2.0&ignoreWarnings=true"},"method":"POST","headers":{"Content-Type":"application/json","authorization":"Bearer ****","content-length":191}}},"body":"{\"_links\":{\"self\":{\"href\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297\"},\"web\":{\"href\":\"http://TFSServer/tfs/_permalink/_build/index?collectionId=3d8b5640-1a02-46f7-a408-0a710daf1be1&projectId=c15b83b5-0351-4c1e-abfb-82195dc28860&buildId=11297\"},\"timeline\":{\"href\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/Timeline\"}},\"properties\":{},\"id\":11297,\"buildNumber\":\"11297\",\"status\":\"notStarted\",\"queueTime\":\"2021-02-09T01:08:46.6414501Z\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297\",\"definition\":{\"type\":\"build\",\"revision\":15,\"id\":100,\"name\":\"WebService ISant├®\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Definitions/100\",\"project\":{\"id\":\"c15b83b5-0351-4c1e-abfb-82195dc28860\",\"name\":\"Cassiopee-Application\",\"description\":\"Projet de d├®veloppement de l'application de gestion Cassiop├®e\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860\",\"state\":\"wellFormed\",\"revision\":29}},\"project\":{\"id\":\"c15b83b5-0351-4c1e-abfb-82195dc28860\",\"name\":\"Cassiopee-Application\",\"description\":\"Projet de d├®veloppement de l'application de gestion Cassiop├®e\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860\",\"state\":\"wellFormed\",\"revision\":29},\"uri\":\"vstfs:///Build/Build/11297\",\"sourceBranch\":\"$/Cassiopee-Application/Main\",\"queue\":{\"pool\":{\"id\":1,\"name\":\"Default\"},\"id\":1,\"name\":\"Default\"},\"priority\":\"normal\",\"reason\":\"manual\",\"requestedFor\":{\"id\":\"8fbe6566-40a1-4f76-a7e5-1e04acb804e8\",\"displayName\":\"[SMIDevCollection]\\\\Comptes de service de la collection de projets\",\"uniqueName\":\"vstfs:///Framework/IdentityDomain/3d8b5640-1a02-46f7-a408-0a710daf1be1\\Comptes de service de la collection de projets\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/8fbe6566-40a1-4f76-a7e5-1e04acb804e8\",\"imageUrl\":\"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=8fbe6566-40a1-4f76-a7e5-1e04acb804e8\",\"isContainer\":true},\"requestedBy\":{\"id\":\"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"displayName\":\"Service de build de collection de projets\",\"uniqueName\":\"Build\\3d8b5640-1a02-46f7-a408-0a710daf1be1\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"imageUrl\":\"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\"},\"lastChangedDate\":\"2021-02-09T01:08:46.8Z\",\"lastChangedBy\":{\"id\":\"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"displayName\":\"Service de build de collection de projets\",\"uniqueName\":\"Build\\3d8b5640-1a02-46f7-a408-0a710daf1be1\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\",\"imageUrl\":\"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe\"},\"parameters\":\"{\\\"serveurDeploiement\\": \\"smi-ws-prod\\"}\",\"orchestrationPlan\":{\"planId\":\"e0a9c5cd-6c75-478b-bbc3-2a218b2a9e95\"},\"logs\":{\"id\":0,\"type\":\"Container\",\"url\":\"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/logs\"},\"repository\":{\"id\":\"$/\",\"type\":\"TfsVersionControl\",\"clean\":null,\"checkoutSubmodules\":false},\"keepForever\":false}"} 2021-02-09T01:08:46.9846545Z Queued new Build for definition WebService ISant├®: http://TFSServer/tfs/SMIDevCollection/Cassiopee-Application/_build/index?buildId=11297 2021-02-09T01:08:46.9846545Z Will wait for queued build to be finished - Refresh time is set to 60 seconds 2021-02-09T01:08:46.9846545Z Following Builds will be awaited: 2021-02-09T01:08:46.9846545Z ##[debug]Sending Request to following url: 2021-02-09T01:08:46.9846545Z ##[debug]build/builds/11297?api-version=2.0 2021-02-09T01:08:47.0002547Z ##[debug]Result: 2021-02-09T01:08:47.0002547Z ##[debug]{"_links":{"self":{"href":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297"},"web":{"href":"http://TFSServer/tfs/_permalink/_build/index?collectionId=3d8b5640-1a02-46f7-a408-0a710daf1be1&projectId=c15b83b5-0351-4c1e-abfb-82195dc28860&buildId=11297"},"timeline":{"href":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/Timeline"},"sourceVersionDisplayUri":{"href":""}},"id":11297,"buildNumber":"11297","status":"notStarted","queueTime":"2021-02-09T01:08:46.6414501Z","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297","definition":{"type":"build","revision":15,"id":100,"name":"WebService ISant├®","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Definitions/100","project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29}},"project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29},"uri":"vstfs:///Build/Build/11297","sourceBranch":"$/Cassiopee-Application/Main","queue":{"pool":{"id":1,"name":"Default"},"id":1,"name":"Default"},"priority":"normal","reason":"manual","requestedFor":{"id":"8fbe6566-40a1-4f76-a7e5-1e04acb804e8","displayName":"[SMIDevCollection]\\Comptes de service de la collection de projets","uniqueName":"vstfs:///Framework/IdentityDomain/3d8b5640-1a02-46f7-a408-0a710daf1be1\Comptes de service de la collection de projets","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/8fbe6566-40a1-4f76-a7e5-1e04acb804e8","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=8fbe6566-40a1-4f76-a7e5-1e04acb804e8","isContainer":true},"requestedBy":{"id":"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","displayName":"Service de build de collection de projets","uniqueName":"Build\3d8b5640-1a02-46f7-a408-0a710daf1be1","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe"},"lastChangedDate":"2021-02-09T01:08:46.8Z","lastChangedBy":{"id":"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","displayName":"Service de build de collection de projets","uniqueName":"Build\3d8b5640-1a02-46f7-a408-0a710daf1be1","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe"},"parameters":"{\"serveurDeploiement\": \"smi-ws-prod\"}","orchestrationPlan":{"planId":"e0a9c5cd-6c75-478b-bbc3-2a218b2a9e95"},"logs":{"id":0,"type":"Container","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/logs"},"repository":{"id":"$/","type":"TfsVersionControl","clean":null,"checkoutSubmodules":false},"keepForever":false} 2021-02-09T01:08:47.0002547Z Build 11297 (WebService ISant├®): http://TFSServer/tfs/_permalink/_build/index?collectionId=3d8b5640-1a02-46f7-a408-0a710daf1be1&projectId=c15b83b5-0351-4c1e-abfb-82195dc28860&buildId=11297 2021-02-09T01:08:47.0002547Z Waiting for builds to finish - This might take a while... 2021-02-09T01:08:47.0002547Z ##[debug]Sending Request to following url: 2021-02-09T01:08:47.0002547Z ##[debug]build/builds/11297?api-version=2.0 2021-02-09T01:08:47.0158549Z ##[debug]Result: 2021-02-09T01:08:47.0158549Z ##[debug]{"_links":{"self":{"href":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297"},"web":{"href":"http://TFSServer/tfs/_permalink/_build/index?collectionId=3d8b5640-1a02-46f7-a408-0a710daf1be1&projectId=c15b83b5-0351-4c1e-abfb-82195dc28860&buildId=11297"},"timeline":{"href":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/Timeline"},"sourceVersionDisplayUri":{"href":""}},"id":11297,"buildNumber":"11297","status":"notStarted","queueTime":"2021-02-09T01:08:46.6414501Z","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297","definition":{"type":"build","revision":15,"id":100,"name":"WebService ISant├®","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Definitions/100","project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29}},"project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29},"uri":"vstfs:///Build/Build/11297","sourceBranch":"$/Cassiopee-Application/Main","queue":{"pool":{"id":1,"name":"Default"},"id":1,"name":"Default"},"priority":"normal","reason":"manual","requestedFor":{"id":"8fbe6566-40a1-4f76-a7e5-1e04acb804e8","displayName":"[SMIDevCollection]\\Comptes de service de la collection de projets","uniqueName":"vstfs:///Framework/IdentityDomain/3d8b5640-1a02-46f7-a408-0a710daf1be1\Comptes de service de la collection de projets","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/8fbe6566-40a1-4f76-a7e5-1e04acb804e8","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=8fbe6566-40a1-4f76-a7e5-1e04acb804e8","isContainer":true},"requestedBy":{"id":"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","displayName":"Service de build de collection de projets","uniqueName":"Build\3d8b5640-1a02-46f7-a408-0a710daf1be1","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe"},"lastChangedDate":"2021-02-09T01:08:46.8Z","lastChangedBy":{"id":"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","displayName":"Service de build de collection de projets","uniqueName":"Build\3d8b5640-1a02-46f7-a408-0a710daf1be1","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe"},"parameters":"{\"serveurDeploiement\": \"smi-ws-prod\"}","orchestrationPlan":{"planId":"e0a9c5cd-6c75-478b-bbc3-2a218b2a9e95"},"logs":{"id":0,"type":"Container","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/logs"},"repository":{"id":"$/","type":"TfsVersionControl","clean":null,"checkoutSubmodules":false},"keepForever":false} 2021-02-09T01:08:47.0158549Z ##[debug]Builds not yet finished...Waiting 60000 seconds 2021-02-09T01:09:47.0298243Z ##[debug]Sending Request to following url: 2021-02-09T01:09:47.0298243Z ##[debug]build/builds/11297?api-version=2.0 2021-02-09T01:09:47.0454245Z ##[debug]Result: 2021-02-09T01:09:47.0454245Z ##[debug]{"_links":{"self":{"href":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297"},"web":{"href":"http://TFSServer/tfs/_permalink/_build/index?collectionId=3d8b5640-1a02-46f7-a408-0a710daf1be1&projectId=c15b83b5-0351-4c1e-abfb-82195dc28860&buildId=11297"},"timeline":{"href":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/Timeline"},"sourceVersionDisplayUri":{"href":""}},"id":11297,"buildNumber":"11297","status":"completed","result":"succeeded","queueTime":"2021-02-09T01:08:46.6414501Z","startTime":"2021-02-09T01:08:48.2482707Z","finishTime":"2021-02-09T01:09:28.5435873Z","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Builds/11297","definition":{"type":"build","revision":15,"id":100,"name":"WebService ISant├®","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/Definitions/100","project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29}},"project":{"id":"c15b83b5-0351-4c1e-abfb-82195dc28860","name":"Cassiopee-Application","description":"Projet de d├®veloppement de l'application de gestion Cassiop├®e","url":"http://TFSServer/tfs/SMIDevCollection/_apis/projects/c15b83b5-0351-4c1e-abfb-82195dc28860","state":"wellFormed","revision":29},"uri":"vstfs:///Build/Build/11297","sourceBranch":"$/Cassiopee-Application/Main","sourceVersion":"10692","queue":{"pool":{"id":1,"name":"Default"},"id":1,"name":"Default"},"priority":"normal","reason":"manual","requestedFor":{"id":"8fbe6566-40a1-4f76-a7e5-1e04acb804e8","displayName":"[SMIDevCollection]\\Comptes de service de la collection de projets","uniqueName":"vstfs:///Framework/IdentityDomain/3d8b5640-1a02-46f7-a408-0a710daf1be1\Comptes de service de la collection de projets","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/8fbe6566-40a1-4f76-a7e5-1e04acb804e8","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=8fbe6566-40a1-4f76-a7e5-1e04acb804e8","isContainer":true},"requestedBy":{"id":"48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","displayName":"Service de build de collection de projets","uniqueName":"Build\3d8b5640-1a02-46f7-a408-0a710daf1be1","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/48f4dadb-5f4f-4ebd-81fc-138d27b1cefe","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=48f4dadb-5f4f-4ebd-81fc-138d27b1cefe"},"lastChangedDate":"2021-02-09T01:09:28.463Z","lastChangedBy":{"id":"8fbe6566-40a1-4f76-a7e5-1e04acb804e8","displayName":"[SMIDevCollection]\\Comptes de service de la collection de projets","uniqueName":"vstfs:///Framework/IdentityDomain/3d8b5640-1a02-46f7-a408-0a710daf1be1\Comptes de service de la collection de projets","url":"http://TFSServer/tfs/SMIDevCollection/_apis/Identities/8fbe6566-40a1-4f76-a7e5-1e04acb804e8","imageUrl":"http://TFSServer/tfs/SMIDevCollection/_api/_common/identityImage?id=8fbe6566-40a1-4f76-a7e5-1e04acb804e8","isContainer":true},"parameters":"{\"serveurDeploiement\": \"smi-ws-prod\"}","orchestrationPlan":{"planId":"e0a9c5cd-6c75-478b-bbc3-2a218b2a9e95"},"logs":{"id":0,"type":"Container","url":"http://TFSServer/tfs/SMIDevCollection/c15b83b5-0351-4c1e-abfb-82195dc28860/_apis/build/builds/11297/logs"},"repository":{"id":"$/","type":"TfsVersionControl","clean":null,"checkoutSubmodules":false},"keepForever":false} 2021-02-09T01:09:47.0454245Z All builds are finished

huserben commented 3 years ago

Hi @tomnie98

sorry for the late response.

Do I assume correctly that the build you are triggering is in the same team project and is using the same repository?

From the logs it looks like everything is fine, the branch name is passed but somehow it seems TFS isn't picking it up.

Edit: You are using TFVC right? Where a branch is actually a dedicated folder and not like a branch in git? I think the use same branch option only really makes sense for git repositories. Sorry I overlooked that first.

HayaTomAs commented 3 years ago

Hi @huserben No problem, I'm just come back from holidays.

Yes, it's same team project and ... TFVC :(

In conclusion, it's not possible to modify with TFVC ??

huserben commented 3 years ago

For my understanding, your use case is that you have a TFVC Repo and there you have multiple branches (that are reflected by different files/folders on the file system right?).

So something like:

If so, then it's not really supported, as you have to point to different folders/files for the complete build. I guess in theory you could design the build with variables for the patht ill the "root" of the branch and work with relative paths from there, and then specify the variable in your build. But for real support with branches I'm afraid you'll need git.

HayaTomAs commented 3 years ago

Hello, Yes, we have one folder by branches.

I can't use variable in repo tab in TFS and download all branches to use only one it's actually not possible (too many branches and spaces on disk :( )

I'm looking for migrate to git if possible, but it seems complicated.

Thanks for help.