Why does TeamCity build old branches?

My configuration

I'm writing some client/server software.  So I have one TeamCity project and two Git repos: one repo for the client and one repo for the server.

The client and server each have their own configuration where they run tests individually.  These configurations are set up on VCS triggers for any branch in the respective client or server repo.

Then, there is also a single configuration that runs integration tests.  It spins up both client and server, and runs a test suite of them talking together over TCP.  The integration configuration has a snapshot dependency on the standalone client configuration and the standalone server configuration.  It is set to be triggered on changes in its dependencies.

The problem

I have some very old branches in both the client and server repository.  For example, there are branches that are there for historical reasons, that haven't been touched since 2009.

For reasons that I do not understand, occasionally TeamCity will decide it really needs to do an integration test between the modern development branch on the server, and some weird branch from 2009 on the client.  (Or vice versa: an old branch on the server and a new one on the client).  These old branches don't build reliably, and it clogs up the agents.  I also get a lot of e-mails telling me that yes, the code quality was bad in 2009.

It's a complete mystery to me why this happens.  These branches show up as "Active" in TeamCity even though nobody has done anything with them in years.  Why?

1 comment
Comment actions Permalink
Hi Drew   (1) sending logs can help identify why the job was triggered. (2) use the branch specification (in the VCS root definition) to exclude all branches, except the main branch you are working on

Please sign in to leave a comment.