title: DataFrame update not saved to a file
body: <p>I'm seeing this weird issue where updates made to a DataFrame are not being written to file. I know for a fact that there are rows which satisfy the condition and should get updated. Maybe I'm missing something very obvious and a fresh set of eyes will help.</p>
  <pre><code>prev_date = (datetime.now() - timedelta(days=1)).strftime('%Y-%m-%d')
  
  df = pd.concat([df1, df2], ignore_index=True) # just for prior context in case it matters
  df.loc[(df['TBL'].str.contains('abc')) &amp; (df['DT'] == prev_date),'FLAG'] = 'Y' # can't see this update in the outfile csv file written
  df.sort_values(by=['TBL']).to_csv('output.csv', index=False)
  </code></pre>
  <p>When I read the output file written above in console and repeat the same steps there, I can see the update happening. Any clue on what I'm missing?</p>
  <p>Structure of <code>df</code>:</p>
  <pre><code>TBL     DT      FLAG
  aab 2020-07-16    Y
  abc 2020-07-15    N
  abb 2020-07-15    N
  </code></pre>
  <p>Update 1: <code>df['DT'] == prev_date</code> strangely is not working</p>
  <p>Update 2: <code>df['DT'].astype(str) == prev_date</code> fixed the issue but don't know why <code>str</code> casting is required when <code>DT</code> is of object type.</p>