Reputation: 1273
We have an SVN repository with some externals hosted at GitHub. All is well in development; GutHub supports being accessed by an SVN client very well.
The problem is with TeamCity. It appears to get the externals by date rather than by revision. We get the following error:
Failed to build patch for build #2.17.7081 {build id=12},
VCS root: svn: https://xxx.xxx.xxx.xx/svn/iaw/trunk {instance id=2, parent id=1}, due to error: Cannot request SVN dated revision:
svn: E200007: Server does not support date-based operations
svn: E200007: The requested report is unknown.
svn: E175002: REPORT of '/cardeliverynetwork/csharp-apiclient.git/!svn/vcc/default': 501 Not Implemented (https://github.com)
SVN server: https://github.com/cardeliverynetwork/csharp-apiclient.git/trunk/src/CarDeliveryNetwork.Types
Used rev: Feb 15, 2013 11:03:24 AM
Rev text:7081_2013/02/15 11:03:24 +0000
Does anyone know how to force TeamCity to simply get HEAD on externals?
Thanks.
Upvotes: 2
Views: 1506
Reputation: 21521
Setting to a specific revision \gitserver\repository\folder@2013 external
works, but setting to head revision \gitserver\repository\folder@HEAD external
does not work.
This is a known bug in TeamCity where if the externals server timezone is behind the teamcity timezone it cannot get the head revision.
TW-2946 Eliminate necessity of synchronized clock between TeamCity server and VCS
There are some possible workarounds here:
TW-27269 TeamCity doesn't pick up changes from svn:externals produced by GitHub
Possible workarounds:
- use fixed revision externals instead of "latest revision" ones
- turn off externals support in the TeamCity VCS root, use agent-side checkout and perform the externals checkout in the first build step of the build in a custom script.
- In TeamCity 8.0.4 we've added an internal property teamcity.svn.ignore.dated.revision.errors, When this property is set to true, TeamCity allows using server-side checkout with SVN externals pointing to GitHub.
Update:
I can confirm the workaround with teamcity.svn.ignore.dated.revision.errors appears to work and we are able to fetch the HEAD revision from Github :)
Upvotes: 0
Reputation: 2326
It seems like I faced a similar issue when I had an external in Subversion itself.
To solve the same I added the exact revision number of the external in the place where I referred it.
It was basically like this
Reference Before: \gitserver\repository\folder external
Reference After : \gitserver\repository\folder@2013 external
Please try adding the revision like this in the properties of the Subversion folder you are referring. This can be edited like this if you go to properties of the folder in Subversion and do property Edit in Advanced mode.
Hope it works though not so sure!
Upvotes: 4