title: How to get rid of cursor id error in mongodb?
body: <p>I have tried the following command in pymongo:</p>
  
  <pre><code>records= db.collection_name.find({"gender":"female"}).batch_size(5)
  </code></pre>
  
  <p>but after a few iterations is gives:</p>
  
  <pre><code>pymongo.errors.CursorNotFound: Cursor not found, cursor id: 61593385827.
  </code></pre>
  
  <p>Also if I try <code>timeout=False</code> in the same command i.e </p>
  
  <pre><code>records= db.collection_name.find({"gender":"female"},timeout=False).batch_size(5) 
  </code></pre>
  
  <p>its gives </p>
  
  <pre><code>TypeError: __init__() got an unexpected keyword argument 'timeout' error.
  </code></pre>