Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect status ("running") reported by webhook on a finished/finishing build #138

Closed
Keilaron opened this issue Jun 20, 2019 · 8 comments
Milestone

Comments

@Keilaron
Copy link

Originally posted by @netwolfuk in #137 (comment)

With regards to the "running" vs "complete" text, I found this recently too. Normally I have complicated builds which have a result of "xx tests passed" or something like that. I created a very simple one recently and noticed it too.

The reason is that the build has not technically completed at the time the webhook fires (it hooks into the finishing event, but a build is not finished until all those event handlers complete), so TeamCity has not set a proper status. I could set it in the payload assembly code, or in the template logic (if a velocity template on 1.2.x). I think doing it in the former location makes more sense. It happens for all events. The most egregious is probably "cancelled" which says it's "running".

Feel free to raise an issue for that. It's a pretty easy fix.

We experience this issue with every build. I think cancelled and error'd builds are reported correctly, but successful ones always show up as "running".

Maybe it would be possible to introduce an async delay to wait for the actual status before reporting the status via the webhook?

@netwolfuk
Copy link
Member

The result might be hard coded in the slack compact template for non-successful results. I'd need to check that.

@Keilaron
Copy link
Author

I do see "Success" if I use the preview on a completed build.

@netwolfuk
Copy link
Member

@netwolfuk
Copy link
Member

I have the code working for this against 1.2. Do you want a special release against 1.1 as well?

It might be a while before 1.2 is out of beta, so just trying to judge your urgency.

netwolfuk added a commit that referenced this issue Jul 5, 2019
@netwolfuk netwolfuk added this to the v1.2 milestone Jul 5, 2019
netwolfuk added a commit that referenced this issue Jul 5, 2019
netwolfuk added a commit that referenced this issue Jul 20, 2019
@netwolfuk
Copy link
Member

@Keilaron
Copy link
Author

Ah, sorry -- I meant to respond to this sooner. This issue I'm not concerned with being released ahead of time (though I would appreciate it of course), and I see you've made another 1.1.x build for the other issue, so I think we're OK for now, thank you. :)

@netwolfuk
Copy link
Member

netwolfuk commented Jul 20, 2019

I have merged this one against 1.1.x.x too, so if you really want it there should be a build on teamcity.jetbrains.com

I haven't done a new release yet though as you have already observed.

@netwolfuk
Copy link
Member

Released

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants