diff mbox

[Branch,~linaro-validation/lava-server/trunk] Rev 260: Import devserver conditionally

Message ID 20111011103514.21793.11907.launchpad@ackee.canonical.com
State Accepted
Headers show

Commit Message

Zygmunt Krynicki Oct. 11, 2011, 10:35 a.m. UTC
------------------------------------------------------------
revno: 260
committer: Zygmunt Krynicki <zygmunt.krynicki@linaro.org>
branch nick: trunk
timestamp: Tue 2011-10-11 11:58:59 +0200
message:
  Import devserver conditionally
modified:
  lava_server/settings/development.py


--
lp:lava-server
https://code.launchpad.net/~linaro-validation/lava-server/trunk

You are subscribed to branch lp:lava-server.
To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-server/trunk/+edit-subscription
diff mbox

Patch

=== modified file 'lava_server/settings/development.py'
--- lava_server/settings/development.py	2011-10-11 09:58:00 +0000
+++ lava_server/settings/development.py	2011-10-11 09:58:59 +0000
@@ -156,7 +156,11 @@ 
 STATICFILES_DIRS = [('lava-server', os.path.join(PROJECT_SRC_DIR, 'htdocs'))]
 
 
-INSTALLED_APPS += ['devserver']
+try:
+    import devserver
+    INSTALLED_APPS += ['devserver']
+except ImportError:
+    pass
 
 # Login redirects back to home
 LOGIN_REDIRECT_URL = '/'