title: Error pd.pivot "MultiIndex.name must be a hashable type"
body: <p>I´m trying to apply to my pandas dataframe something similar to R's tidyr::spread . I saw in some places people using pd.pivot but so far I had no success. </p>
  
  <p>So in this example I have the following dataframe DF:</p>
  
  <pre><code>df = pd.DataFrame({'action_id' : [1,2,1,4,5],
                 'name': ['jess', 'alex', 'jess', 'cath', 'mary'],
                'address': ['house', 'house', 'park', 'park', 'park'],
                 'date': [ '01/01', '02/01', '03/01', '04/01', '05/01']})
  </code></pre>
  
  <p>How does it look like:</p>
  
  <p><a href="https://i.stack.imgur.com/d7IV4.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/d7IV4.png" alt="enter image description here"></a></p>
  
  <p>Ok, so what I want is a multi-index pivot table having 'action_id' and 'name' as index, "spread" the address column and fill it with the 'date' column. So my df would look like this:</p>
  
  <p><a href="https://i.stack.imgur.com/49lDU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/49lDU.png" alt="enter image description here"></a></p>
  
  <p>What I tryed to do was:</p>
  
  <pre><code>df.pivot(index = ['action_id', 'name'], columns = 'address', values = 'date')
  </code></pre>
  
  <p>And I got the error <em>TypeError: MultiIndex.name must be a hashable type</em></p>
  
  <p>Does anyone know what am I doing wrong?</p>