]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
bitbake: toaster: Prevent deprecation warnings for RedirectView
authorElliot Smith <elliot.smith@intel.com>
Thu, 10 Dec 2015 03:56:33 +0000 (19:56 -0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 14 Dec 2015 23:13:07 +0000 (23:13 +0000)
The API for RedirectView is due to change in Django 1.9, which
means that Toaster generates deprecation warnings.

Set the "permanent" flag when constructing RedirectView instances
to prevent this warning.

[YOCTO #8364]

(Bitbake rev: 4aa09488bfe65cb365356b320cd9865643bb4fe5)

Signed-off-by: Elliot Smith <elliot.smith@intel.com>
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: brian avery <avery.brian@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
bitbake/lib/toaster/bldcollector/urls.py
bitbake/lib/toaster/toastergui/urls.py
bitbake/lib/toaster/toastermain/urls.py

index 144387b56a70c84c9ac6c42e759f83abcbbed2af..64722f2cdc58bbd6fd50c49e815343c5089ffe56 100644 (file)
@@ -18,7 +18,6 @@
 
 
 from django.conf.urls import patterns, include, url
-from django.views.generic import RedirectView
 
 urlpatterns = patterns('bldcollector.views',
         # landing point for pushing a bitbake_eventlog.json file to this toaster instace
index a1adbb7be0210a7c7ea298674a6169ca86aea2b8..2bf2d99ae741ceb0871d39aa2a39379e2f48a6ea 100644 (file)
@@ -168,5 +168,5 @@ urlpatterns = patterns('toastergui.views',
             name='xhr_customrecipe'),
 
           # default redirection
-        url(r'^$', RedirectView.as_view( url= 'landing')),
+        url(r'^$', RedirectView.as_view(url='landing', permanent=True)),
 )
index 5ce5a924d8c19a154d1b2c53f2db9a4afaf908e6..534679dc50049f4f3e1a0fbb71c553e17c7e615e 100644 (file)
@@ -45,7 +45,7 @@ urlpatterns = patterns('',
     url(r'^orm/eventfile$', 'bldcollector.views.eventfile'),
 
     # if no application is selected, we have the magic toastergui app here
-    url(r'^$', never_cache(RedirectView.as_view(url='/toastergui/'))),
+    url(r'^$', never_cache(RedirectView.as_view(url='/toastergui/', permanent=True))),
 )
 
 import toastermain.settings