Monday, May 15, 2017

TDS Error - VerifyTDSVersion task failed unexpectedly

I've received this error several times now, and it feels like each time it stems from a different issue, so I'm going to update this post every time I receive this error to track the different possible solutions.



1. Restart Visual Studio
This error often happens when adding a new TDS Project to an existing solution, and then immediately trying to compile. In this case, I just restarted Visual Studio and the new TDS Project compiled without errors.

2. TDS Version Mismatch
We use the HedgehogDevelopment.TDS.x.x.x.x.nupkg NuGet package to allow our VSO to compile TDS projects without having to install anything on the VSO server. With multiple developers working on a project, not all are always sync'd on the same version of TDS. Having a lower version of TDS installed on your local Visual Studio than the NuGet package version being used has caused this error before.

Thursday, May 11, 2017

Issue: Octopus Deploy, Sitecore CD server receiving an older build

I have a project that is setup for CI/CD using VSO and Octopus. VSO has a build definition that compiles the code twice, once under a Release-CM configuration and once under a Release-CD configuration (to take advantage of transforms). Both generate a TDS Update package to be pushed to my Sitecore servers.

I was running into an issue where Octopus was installing the most recent CM Update package, but was sometimes installing the previous build's CD package.

It turns out the problem stemmed from how VSO was interacting with the Trigger in Octopus that was generating the new Release. VSO would build the Release-CM first, which would generate the CM Update package and send it to Octopus, then build the Release-CD second, and send the CD Update package to Octopus. Octopus was triggering a Release when it got the CM Update package, and sometimes the CD Update package was making it in time to be included in the Release, and other times it wasn't so Octopus was just using the most recent version it had (the previous build's version).


The solution was to switch the Trigger to wait for the CD Update package before generating the Release. Easy!