title: Python import similar to Django settings file
body: <p>I am trying to use a *.py file to take variables from and use them across multiple imports in my python application, similar to how a Django settings file works.</p>
  
  <p>An example settings file:</p>
  
  <pre><code>DB_NAME = 'foo'
  DB_TABLE = 'bar'
  #Lots of other variable names and values here
  </code></pre>
  
  <p>The benefit is that I can load different settings very quickly this way. I can reference a sort of global "DB_NAME" wherever I want without having specific objects to deal with.</p>
  
  <p>The drawback is that I have to change the import statement in every file that has to import them. </p>
  
  <p>Can I set it up so that I import the file once and then reference a generic import to get all of these values?</p>
  
  <p>Or is there a much better way to do this?</p>
  
  <p>Any help is appreciated.</p>
  
  <p>EDIT: The problem stems from having multiple settings files. I would have to import settings.py for one file, or if I want a different settings file, I would need to change all the import statements to reference test_settings.py, etc..</p>
  
  <p>I don't want to manually change the import locations in order to change what is imported across the entire application.</p>