title: Python thread release
body: <p>I running 2 thread in python and execute the function <code>Do()</code>.</p>
  
  <pre><code>import sys, threading
  
  def do():
      print ("Execute")
  
  def run():
      def start_thread():
          thread = threading.Thread(target = do)
          thread.start()
          thread.join()
          return thread
  
      t1 = start_thread()
      t2 = start_thread()
  
  run()
  print('Press enter to Quit')
  sys.stdin.readline()
  </code></pre>
  
  <p>After running the <code>run()</code> function, the threads <code>t1</code> and <code>t2</code> are out of scope. But, according to VS-Code, they are still in <strong>Running</strong> mode. </p>
  
  <p><a href="https://i.stack.imgur.com/D7xRo.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/D7xRo.png" alt="enter image description here"></a></p>
  
  <p>I wait for them to <code>join()</code>. This mean that they are terminated. So, how they are still running? How to release those threads safely?</p>