Ticket #2312 (closed enhancement: worksforme)
Add the build status to build properties
| Reported by: | krf | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | 0.9.+ |
| Version: | 0.8.6p1 | Keywords: | |
| Cc: |
Description
Scenario: We'd like to add the build status as a custom mail header.
For this to work (properly) we need a way to access the build status from 'WithProperties?' to pass it to MailNotifier?'s extraHeaders.
Change History
comment:1 Changed 11 months ago by dustin
- Keywords mail added; status build property removed
- Milestone changed from 0.8.+ to 0.9.+
comment:3 Changed 11 months ago by krf
Yep. That's what we did for now.
For other people interested in this, here's the code:
class BuildStatusRenderable(util.ComparableMixin):
implements(interfaces.IRenderable)
def getRenderingFor(self, props):
build = props.getBuild()
results = build.results
return Results[results]
extraHeaders = {
'X-Build-Status': BuildStatusRenderable()
}
Feel free to close this.
Thanks
Note: See
TracTickets for help on using
tickets.
![[Buildbot Logo]](/chrome/site/header-text-transparent.png)
I think that this is something where your custom mail notifier would be querying data from the data API.