Patchwork [bitbake-devel,87/94] bitbake: webhob: Clean up links in Simple UI

login
register
mail settings
Submitter Alexandru DAMIAN
Date Sept. 24, 2013, 4:52 p.m.
Message ID <32fd9ea1ed40f33680693ccd88f3318f37c8b51d.1380041477.git.alexandru.damian@intel.com>
Download mbox | patch
Permalink /patch/58777/
State New
Headers show

Comments

Alexandru DAMIAN - Sept. 24, 2013, 4:52 p.m.
From: Alexandru DAMIAN <alexandru.damian@intel.com>

This patch fixes 404s and 500 errors coming up on
a spidering of the UI simple interface.

Test used:  wget -r -l 6 http://localhost:8000/

For log, look up build/whbmain.log file.

Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
---
 bitbake/lib/webhob/bldviewer/templates/build.html | 2 +-
 bitbake/lib/webhob/bldviewer/views.py             | 1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

Patch

diff --git a/bitbake/lib/webhob/bldviewer/templates/build.html b/bitbake/lib/webhob/bldviewer/templates/build.html
index dd0e5c0..bd7e0f3 100644
--- a/bitbake/lib/webhob/bldviewer/templates/build.html
+++ b/bitbake/lib/webhob/bldviewer/templates/build.html
@@ -27,7 +27,7 @@ 
             <td><a href="/simple/build/{{build.id}}/configuration/">{{build.get_outcome_display}}</a></td>
             <td>{{build.started_on}}</td>
             <td>{{build.completed_on}}</td>
-            <td>{% for t in build.target_set.all %}<a href="/simple/build/{{build.id}}/target/{{t.id}}">{{t.target}}</a><br/>{% endfor %}</td>
+            <td>{% for t in build.target_set.all %}<a href="/simple/build/{{build.id}}/target/{{t.id}}/packages/">{{t.target}}</a><br/>{% endfor %}</td>
             <td>{% if build.is_image %} <a href="/simple/build/{{build.id}}/package/">{{build.is_image}}</a>{% else %} {{build.is_image}} {% endif %}</td>
             <td>{{build.machine}}</td>
             <td>{% time_difference build.started_on build.completed_on %}</td>
diff --git a/bitbake/lib/webhob/bldviewer/views.py b/bitbake/lib/webhob/bldviewer/views.py
index 98099ee..b7bac73 100644
--- a/bitbake/lib/webhob/bldviewer/views.py
+++ b/bitbake/lib/webhob/bldviewer/views.py
@@ -52,7 +52,6 @@  def tpackage(request, build_id, target_id):
     template = 'package.html'
 
     packages = Target_Package.objects.filter(target=target_id)
-    package_depends = Target_Package_Dependency.objects.filter(package__in=packages)
 
     context = {'build' : Build.objects.filter(pk=build_id)[0],'packages': packages}