title: Dictionary/key word unpacking - must be strings
body: <p>I have created a function</p>
  
  <pre><code>&gt;&gt;&gt; fun(a,b,c):
    print(a,b,c)
  </code></pre>
  
  <p>Which I can pass a list to, say <code>[1,2,3]</code> by unpacking and we have</p>
  
  <pre><code>&gt;&gt;&gt; fun(*[1,2,3])
  
  1, 2, 3
  </code></pre>
  
  <p>or I can pass a dictionary <code>d = {1:'a',2:'b',3:'c'}</code></p>
  
  <pre><code>&gt;&gt;&gt; fun(*d)
  1, 2, 3
  </code></pre>
  
  <p>However, I experience a problem when I attempt to unpack the keyword arguments</p>
  
  <pre><code>Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
  TypeError: fun() keywords must be strings
  </code></pre>
  
  <p>and when I reverse the values and the keys  <code>d = {'a':1,'b':2,'c':3}</code></p>
  
  <pre><code>&gt;&gt;&gt; fun(**d)
  Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
  TypeError: fun() got an unexpected keyword argument 'a'
  
  </code></pre>
  
  <p>So, two questions: Why does python only allow strings to be keyword arguments (or have I made a mistake)? And why, do I get an unexpected keyword argument when what it's referencing seems clear?</p>