title: using of extra **kwargs in python: how to access the extra variables?
body: <p>I have a seemingly easy question which I can't find an answer to.
  With a simple function such as the following:</p>
  
  <pre><code>def test_kwargs_1(a,**kwargs):
      print a
      print b
  </code></pre>
  
  <p>I was thinking that, if I passed:</p>
  
  <pre><code>kwargs = {'a':1,'b':2}
  test_kwargs_1(**kwargs)
  </code></pre>
  
  <p>it would print:</p>
  
  <pre><code>1
  2
  </code></pre>
  
  <p>as it would unpack "kwargs" and both a variable "a" and "b" would be available.
  Instead i get:</p>
  
  <pre><code>1
  ---------------------------------------------------------------------------
  NameError                                 Traceback (most recent call last)
  .
  .
  ----&gt; 3     print b
  NameError: global name 'b' is not defined
  </code></pre>
  
  <p>I understand that "b" is a variable which may or may not exist, but I thought that the unpacking of kwargs would make the variable "b" available if explicitly defined in kwargs.
  What am I not getting?
  Thanks,
  s</p>