NCover failing due to 'Parameter "system.teamcity.build.checkoutDir" is undefined.'

Any idea why I am getting the following error in all my build logs which use NCover:

Parameter "system.teamcity.build.checkoutDir" is undefined.

I thought the paramter referenced in the error message was defined by TeamCity?  Is that incorrect?  The 6.5.x docs seem to imply this:

In your build script you may refer to the effective value of build checkout directory via the teamcity.build.checkoutDir property provided by TeamCity.

Best Regards,
Andrew Frarser

4 comments
Comment actions Permalink

Hi Andrew

As stated at Predefined Build Parameters page:

  • Make sure to replace "." with "_" when using properties in MSBuild scripts. That is useteamcity_dotnet_nunitlauncher_msbuild_task instead ofteamcity.dotnet.nunitlauncher.msbuild.task
0
Comment actions Permalink

Hi Michael,

I am not using the property in my configuration at all.  The error occurs just after the checkout:

[12:28:43]: Checking for changes
[12:29:36]: Clearing temporary directory: x
[12:29:36]: Checkout directory: x
[12:29:36]: Updating sources: agent side checkout... (1m:33s)
[12:29:36]: [Updating sources: agent side checkout...] Will perform clean checkout. Reason: Checkout directory is empty or doesn't exist
[12:29:36]: [Updating sources: agent side checkout...] Cleaning x
[12:29:36]: [Updating sources: agent side checkout...] VCS Root: x (1m:33s)
[12:29:36]: [VCS Root: x] revision: x
[12:31:10]: Swabra (3s)
[12:31:10]: [Swabra] Saving x directory state to snapshot file 7a800701.snapshot
[12:31:13]: Resolving artifact dependencies (4s)
[12:31:13]: [Resolving artifact dependencies] Destination directory cleaned: x
[12:31:13]: [Resolving artifact dependencies] Destination directory cleaned: x
[12:31:15]: [Resolving artifact dependencies] 1 files retrieved for [x] downloading pattern
[12:31:18]: [Resolving artifact dependencies] 33 files retrieved for [x] downloading pattern
[12:31:18]: Parameter "system.teamcity.build.checkoutDir" is undefined.
[12:31:18]: Publishing internal artifacts (3s)
[12:31:22]: [Publishing internal artifacts] Sending build.start.properties.gz file
[12:31:18]: Step 1/2: MSBuild (24s)

Cheers,
Andrew

0
Comment actions Permalink

Please check how artifact dependencies are configured for this build configuration.
It looks like that parameter is used in artifact path rules there. Change them to relative paths.

0
Comment actions Permalink

Hi Michael,

I don't use the parameter in my artifact dependency at all:

TeamCityDependencies.PNG

The path rules both start with a folder name e.g. test\bin.

Cheers,
Andrew

0

Please sign in to leave a comment.