title: Python Multiprocessing - How to pass kwargs to function?
body: <p>How do I pass a dictionary to a function with Python's Multiprocessing? The Documentation: <a href="https://docs.python.org/3.4/library/multiprocessing.html#reference" rel="nofollow noreferrer">https://docs.python.org/3.4/library/multiprocessing.html#reference</a> says to pass a dictionary, but I keep getting</p>
  <pre><code>TypeError: fp() got multiple values for argument 'what'
  </code></pre>
  <p>Here's the code:</p>
  <pre><code>from multiprocessing import Process, Manager
     
  def fp(name, numList=None, what='no'):
          print ('hello %s %s'% (name, what))
          numList.append(name+'44')
   
  if __name__ == '__main__':
  
      manager = Manager()
   
      numList = manager.list()
      for i in range(10):
          keywords = {'what':'yes'}
          p = Process(target=fp, args=('bob'+str(i)), kwargs={'what':'yes'})
          p.start()
          print(&quot;Start done&quot;)
          p.join()
          print(&quot;Join done&quot;)
      print (numList)
  </code></pre>