From f4d0898a716aef02cc0daff331f3ccfa6c5a4e71 Mon Sep 17 00:00:00 2001 From: Tomas Kopecek Date: Tue, 8 Sep 2020 15:46:12 +0200 Subject: [PATCH] web: urlquote buildtarget/buildtag names Fixes: https://pagure.io/koji/issue/2468 --- www/kojiweb/taskinfo_params.chtml | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/www/kojiweb/taskinfo_params.chtml b/www/kojiweb/taskinfo_params.chtml index e98563b3..2bd7ef28 100644 --- a/www/kojiweb/taskinfo_params.chtml +++ b/www/kojiweb/taskinfo_params.chtml @@ -1,3 +1,4 @@ +#from urllib.parse import quote #import koji #from kojiweb import util @@ -37,7 +38,7 @@ $value #if $task.method == 'buildSRPMFromSCM' SCM URL: $params[0]
#if $len($params) > 1 -Build Tag: $buildTag
+Build Tag: $buildTag
#end if #if $len($params) > 2 $printOpts($params[2]) @@ -46,7 +47,7 @@ $printOpts($params[2]) CVS URL: $params[0] #elif $task.method == 'buildArch' SRPM: $params[0]
-Build Tag: $buildTag
+Build Tag: $buildTag
Arch: $params[2]
Keep SRPM? #if $params[3] then 'yes' else 'no'#
#if $len($params) > 4 @@ -65,7 +66,7 @@ $printOpts($params[4]) #else Build Target: (no build target)
#end if -Web URL: $params[3] +Web URL: $params[3] #elif $task.method == 'tagNotification' Recipients: $printValue('', $params[0])
Successful?: #if $params[1] then 'yes' else 'no'#
@@ -83,11 +84,11 @@ $printOpts($params[4]) #end if #elif $task.method == 'build' Source: $params[0]
-Build Target: $params[1]
+Build Target: $params[1]
$printOpts($params[2]) #elif $task.method == 'maven' SCM URL: $params[0]
-Build Target: $params[1]
+Build Target: $params[1]
$printOpts($params[2]) #elif $task.method == 'buildMaven' SCM URL: $params[0]
@@ -99,7 +100,7 @@ $printOpts($params[2]) Spec File URL: $params[0]
#if 'locked' in $buildTarget #set $buildTag = $buildTarget.name -Build Tag: $buildTag
+Build Tag: $buildTag
#else Build Target: $buildTarget.name
#end if @@ -119,7 +120,7 @@ $printOpts($params[4]) $key:$printMap($val) #end for -Build Target: $params[1]
+Build Target: $params[1]
#if $len($params) > 2 $printOpts($params[2]) #end if @@ -127,12 +128,12 @@ $printOpts($params[2]) Name: $params[0]
Version: $params[1]
Arch: $params[2]
-Build Target: $params[3]
+Build Target: $params[3]
Kickstart File: $params[4]
$printOpts($params[5]) #elif $task.method == 'image' Arches: #echo ', '.join($params[2])#
-Build Target: $params[3]
+Build Target: $params[3]
Installation Tree: $params[4]
$printOpts($params[5]) #elif $task.method == 'createLiveCD' or $task.method == 'createAppliance' or $task.method == 'createLiveMedia' @@ -146,7 +147,7 @@ $printOpts($params[8]) #else ## old method signature Arch: $params[0]
-Build Target: $params[1]
+Build Target: $params[1]
Kickstart File: $params[2]
#if $len($params) > 3 $printOpts($params[3]) @@ -154,13 +155,13 @@ $printOpts($params[3]) #end if #elif $task.method == 'createImage' #set $target = $params[4] -Build Target: $target.name
+Build Target: $target.name
Install Tree: $params[7]
$printOpts($params[8]) #elif $task.method == 'winbuild' VM: $params[0]
SCM URL: $params[1]
-Build Target: $params[2]
+Build Target: $params[2]
#if $len($params) > 3 $printOpts($params[3]) #end if @@ -228,7 +229,7 @@ $printMap($subtask[2], '    ') #set $groupNum += 1   $groupNum: #echo ', '.join($urls)#
#end for -Build Target: $params[1]
+Build Target: $params[1]
$printOpts($params[2]) #elif $task.method == 'waitrepo' Build Tag: $params[0]