Public bug reported:

In my deployed environment, I add some configure items at end of file
dashboard/settings.py as default values. Try to overwrite some in
openstack_dashboard/local/local_settings.py but failed.  I find the
following codes do the overwriting work:

try:
    from local.local_settings import *  # noqa
except ImportError:
    logging.warning("No local_settings file found.")

To ensure overwrite working, all the default configurations in
settings.py(could be customized in local_settings.py) should be above
line:"from local.local_settings import *".

So we should move all customizable configurations above "from
local.local_settings import *".

** Affects: horizon
     Importance: Undecided
     Assignee: Wang Bo (chestack)
         Status: New

** Changed in: horizon
     Assignee: (unassigned) => Wang Bo (chestack)

** Description changed:

  In my deployed environment, I add some configure items at end of file
  dashboard/settings.py as default values. Try to overwrite some in
  openstack_dashboard/local/local_settings.py but failed.  I find the
  following codes do the overwriting work:
  
  try:
-     from local.local_settings import *  # noqa
+     from local.local_settings import *  # noqa
  except ImportError:
-     logging.warning("No local_settings file found.")
+     logging.warning("No local_settings file found.")
  
- To ensure overwrite working, all the customizable configurations should
- be above "from local.local_settings import *".
+ To ensure overwrite working, all the default configurations in
+ settings.py(could be customized in local_settings.py) should be above
+ line:"from local.local_settings import *".
  
- So we should move all customizable configurations should be above "from
+ So we should move all customizable configurations to be above "from
  local.local_settings import *".

** Description changed:

  In my deployed environment, I add some configure items at end of file
  dashboard/settings.py as default values. Try to overwrite some in
  openstack_dashboard/local/local_settings.py but failed.  I find the
  following codes do the overwriting work:
  
  try:
      from local.local_settings import *  # noqa
  except ImportError:
      logging.warning("No local_settings file found.")
  
  To ensure overwrite working, all the default configurations in
  settings.py(could be customized in local_settings.py) should be above
  line:"from local.local_settings import *".
  
- So we should move all customizable configurations to be above "from
+ So we should move all customizable configurations above "from
  local.local_settings import *".

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1527042

Title:
  All customizable configurations should be above "from
  local.local_settings import *"

Status in OpenStack Dashboard (Horizon):
  New

Bug description:
  In my deployed environment, I add some configure items at end of file
  dashboard/settings.py as default values. Try to overwrite some in
  openstack_dashboard/local/local_settings.py but failed.  I find the
  following codes do the overwriting work:

  try:
      from local.local_settings import *  # noqa
  except ImportError:
      logging.warning("No local_settings file found.")

  To ensure overwrite working, all the default configurations in
  settings.py(could be customized in local_settings.py) should be above
  line:"from local.local_settings import *".

  So we should move all customizable configurations above "from
  local.local_settings import *".

To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1527042/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to