code: def bytes_hack(buf):
      
      ub = None
      if sys.version_info > (3,):
          ub = buf
      else:
          ub = bytes(buf)
  
      return ub
docs: Hacky workaround for old installs of the library on systems without python-future that were
      keeping the 2to3 update from working after auto-update.