Last build in chain is done twice when VCS trigger is set

I have two projects in one SVN root, A and B. Project A is a library which produces an artifact. No build trigger is set for A.

The other project B is depending on A, two dependencies are set: one snapshot dependency ("Do not run new build if there is a suitable one", "Only use successful builds from suitable ones"), and one artifact dependency on A's artifact ("Build from the same chain").

Moreover, B has one build trigger set: VCS trigger ("Trigger a build on changes in snapshot dependencies").

Now the problem is this: When I check-in multiple files in one commit, belonging to both projects, then A is triggered correctly, but B is triggered (and built) twice. It seems the VCS trigger  of B fires twice, even though the second build of B is unnecessary.

Any ideas what I might do to solve this issue?

6 comments
Comment actions Permalink

Hi Matthias,

Do you actually need finish build trigger to be configured? It seems that VCS trigger with "Trigger a build on changes in snapshot dependencies" option is enough.

0
Comment actions Permalink

Hi Alina, thanks for your reply.

I removed the "Finish Build" trigger, but project B is still built twice.
I have noticed three different cases:

  1. Commit of file(s) for project A only --> New build of A, then new build of B --> correct
  2. Commit of file(s) for project B only --> New build of B only --> correct
  3. Commit of files for both projects A and B --> New build of A, then new build of B, then a 2nd build of B --> incorrect


Is this a bug in TeamCity, or do I need to change my triggers/dependencies configuration?

0
Comment actions Permalink

Do you have "Trigger a build on each check-in" option enabled in VCS trigger?
Please reproduce the issue and attach teamcity-server.log file and screenshot of VCS trigger.

Also we have the related issue https://youtrack.jetbrains.com/issue/TW-17639, please check that it is not the case.

0
Comment actions Permalink

No, I do not have the option "Trigger a build on each check-in" enabled.
Here is my trigger configuration (the only trigger for project B):

TC-Trigger.png

I have attached the teamcity-server.log file, as requested.
The last build in the log is the one started twice.

Thanks for your support!



Attachment(s):
teamcity-server.log.zip
0
Comment actions Permalink

Hi Matthias,

We found a bug in TeamCity 9.0.2 https://youtrack.jetbrains.com/issue/TW-40270, which has been already fixed in 9.0.3. Please upgrade to 9.0.3 when that becomes available (probably within few weeks).

0
Comment actions Permalink

Thanks, I will try version 9.0.3 as soon as it is available.

0

Please sign in to leave a comment.