title: How to make the debugger step through the whole program?
body: <pre><code>import gym
  env = gym.make('CartPole-v0')
  env.reset()
  for _ in range(100):
      env.render()
      env.step(env.action_space.sample()) # take a random action
  </code></pre>
  
  <p>This is an example from the <a href="https://gym.openai.com/docs/" rel="nofollow noreferrer">OpenAI gym</a>. 'Step into' works neither on the <code>import gym</code> nor on any of the method calls for <code>env</code>, it just skips over them to the next statement. I am new to Python, but not to programming at this point.</p>
  
  <p>In order to build intuition on how exactly <code>gym</code> and various Python libraries work I'd like as an exercise to go through them step by step. There is also a plotting issue in all the PyTorch examples and now this one where the window freezes after being run that has something to do with async handling.</p>
  
  <p>Since I'd like to use Python specifically for its interactivity, I want to look into this. How could this be done?</p>