[PATCH] Revert to getfile urls if the task is not successful (closed).

Jesse Keating jkeating at redhat.com
Sun Jan 13 15:47:30 UTC 2008


This is needed because unless the task is closed, the log files won't
be in the packages/ tree, and the email will reference 404 urls.
---
 builder/kojid |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/builder/kojid b/builder/kojid
index f4b7509..c03af74 100755
--- a/builder/kojid
+++ b/builder/kojid
@@ -2118,7 +2118,10 @@ Build Info: %(weburl)s/buildinfo?buildID=%(build_id)i\r
                                 if filetype == 'rpms':
                                     output += " %s\r\n" % '/'.join([options.pkgurl, build['name'], build['version'], build['release'], task['build_arch'], file])
                                 elif filetype == 'logs':
-                                    output += " %s\r\n" % '/'.join([options.pkgurl, build['name'], build['version'], build['release'], 'data', 'logs', task['build_arch'], file])
+                                    if tasks[task_state] != 'closed':
+                                        output += "  %s/getfile?taskID=%s&name=%s\r\n" % (weburl, task['id'], file)
+                                    else:
+                                        output += " %s\r\n" % '/'.join([options.pkgurl, build['name'], build['version'], build['release'], 'data', 'logs', task['build_arch'], file])
                                 elif task[filetype] == 'misc':
                                     output += "  %s/getfile?taskID=%s&name=%s\r\n" % (weburl, task['id'], file)
                     output += "\r\n"
-- 
1.5.3.8


-- 
Jesse Keating
Fedora -- All my bits are free, are yours?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Revert-to-getfile-urls-if-the-task-is-not-successful.patch
Type: text/x-patch
Size: 1740 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/fedora-buildsys-list/attachments/20080113/1d6d6452/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/fedora-buildsys-list/attachments/20080113/1d6d6452/attachment.sig>


More information about the Fedora-buildsys-list mailing list