title: How do you access a variable defined by other modules user input?
body: <p>I am writing a program: <em>prog1</em> which is importing another module to define a variable.<br />
  It works like so:</p>
  <pre class="lang-py prettyprint-override"><code>import modulename1
  var1 = attribute1 #situated in modulename1
  import modulename2
  var2 = attribute2()
  function2(var1):       # Imagine this being a api call with var1 part of url 
       #api call
       return response.text
  function3(function2(var1)+ var2)  
  </code></pre>
  <p>modulename1:</p>
  <pre class="lang-py prettyprint-override"><code>attribute1 = input('user value')
  </code></pre>
  <p>modulename2:</p>
  <pre class="lang-py prettyprint-override"><code>def attribute2():
     from prog 1 import var 1
     atr2 = function(var1) + 'word'    #Imagine the function as an api call at 
     return atr2                       #this space
  </code></pre>
  <p><em>modulename1</em> accepts user <code>input</code> to define the variable <em>attribute1</em>.
  now another module: <em>modulename2</em> needs to import the <em>var1</em> with the value from <em>modulename1</em>.<br />
  It can´t however import directly from <em>modulename1</em> as <em>prog 1</em> is the program launched by the User and importing <em>modulename1</em> again could result in different user <code>input</code>.<br />
  <em>modulename2</em> in Turn processes <em>var1</em> and defines <em>attribute2</em>.<br />
  <em>var2</em> is then used in <em>prog1</em> again. Is there any way to do that?</p>
  <p><strong>conditions</strong></p>
  <ul>
  <li><p>Both modules have to be imported completely.</p>
  </li>
  <li><p>for obvious reasons modulename2 shouldn´t import modulename1</p>
  </li>
  </ul>