title: Where to put meta info (__version__ etc) in a Python project?
body: <p>I have a little Python2/3 project with the directory structure</p>
  
  <pre><code>superproject/
      -&gt;  __init__.py
      -&gt;  meta.py
  setup.py
  </code></pre>
  
  <p>The <code>__init__.py</code> file contains a bunch of <code>import</code>s and actual code, meta has</p>
  
  
  
  <pre><code> __author__ = 'John Doe'
   __author_email__ = 'john@doe.com'
   __version__ = '1.2.3'
   # [...]
  </code></pre>
  
  <p>I would like to make the meta info available in setup.py (simple: just <code>import superproject.meta</code>) and in <code>superproject</code> as</p>
  
  
  
  <pre><code>import superproject
  print(superproject.__version__)
  </code></pre>
  
  <p>I'm struggling with the latter requirement. When doing </p>
  
  <pre><code>from .meta import *
  </code></pre>
  
  <p>in <code>__init__.py</code>, I can only do</p>
  
  <pre><code>print(superproject.meta.__version__)
  </code></pre>
  
  <p>for example.</p>
  
  <p>Note that, I cannot put the meta info in <code>__init__.py</code> directly since I'd have to <code>import superproject</code> in <code>setup.py</code>, and the numerous <code>import</code> dependencies of <code>superproject</code> aren't available then yet.</p>
  
  <p>Any hints?</p>