title: How do I call setattr() on the current module?
body: <p>What do I pass as the first parameter "<code>object</code>" to the function <code>setattr(object, name, value)</code>, to set variables on the current module?</p>
  
  <p>For example:</p>
  
  <pre><code>setattr(object, "SOME_CONSTANT", 42);
  </code></pre>
  
  <p>giving the same effect as:</p>
  
  <pre><code>SOME_CONSTANT = 42
  </code></pre>
  
  <p>within the module containing these lines (with the correct <code>object</code>).</p>
  
  <p>I'm generate several values at the module level dynamically, and as I can't define <code>__getattr__</code> at the module level, this is my fallback.</p>