title: Local & Prod Settings.py in Django
body: <p>I've implemented the normal way to do <code>local</code> and <code>prod</code> with two <code>settings.py</code> files and an <code>__init__.py</code>:</p>
  <pre><code>from .base import *
  
  from .production import *
  
  try:
      from .local import *
  except:
      pass
  </code></pre>
  <p>The problem is that in some of my <code>views.py</code> files, there is also <strong>specific functionality depending on <code>local</code> or <code>prod</code></strong>, for example integrating <code>django axes</code> in <code>prod</code>.</p>
  <p>How can I check if I use the local or prod settings file in my <code>views.py</code> files? Thanks!!</p>