title: How to monitor progress of a HTTP PUT upload using Python Requests and Clint
body: <p>I am writing a simple commandline application - <a href="https://github.com/0x27/transfer.py" rel="nofollow">transfer.py</a> - to allow for uploading and downloading files from the transfer.sh service as a learning exercise, using the 'requests' library for HTTP. Thanks to some answers on here, I was able to implement a progress bar using python-clint and python-requests for monitoring the file download - said functionality being seen <a href="https://github.com/0x27/transfer.py/blob/master/transfer.py#L32,L38" rel="nofollow">here</a>.</p>
  
  <p>Anyway, I got very, very lost when trying to implement the same kind of progress bar to monitor the upload - which uses HTTP PUT. I understand conceptually it should be very similar, but cannot for some reason figure it out, and would be very thankful if someone could point me in the right direction on this. I tried a few methods using multipart encoders and suchlike, but those lead to the file being mangled on the way up (the service accepts raw PUT requests, and multipart encoding messes it up seemingly).</p>
  
  <p>The end goal is to write a script to AES encrypt the file to be uploaded with a random key, upload it to the service, and print a link + encryption key that can be used by a friend to download/decrypt the file, mostly for fun and to fill in some knowledge-gaps in my python.</p>