Fix posting with utf-8 changes.

Review Request #6721 — Created Jan. 1, 2015 and submitted

Information

RBTools
master
72d8f5e...

Reviewers

This fixes a regression from the UTF-8 changes that I made recently. In a few
places, we were passing unicode objects in for the HTTP method or headers. For
the most part, this was fine because internally, HTTPRequest would concatenate
everything into one big unicode string and then encode it as ascii before
sending it on the wire. Unfortunately, if the posted changes (or description)
included any unicode characters, it would try to encode as ascii and fail.
Keeping everything that goes to httplib as bytes will avoid this.

Successfully posted a change that included utf-8 characters in the diff.

reviewbot
  1. Tool: Pyflakes
    Processed Files:
        rbtools/api/request.py
        rbtools/api/resource.py
        rbtools/api/cache.py
    
    
    
    Tool: PEP8 Style Checker
    Processed Files:
        rbtools/api/request.py
        rbtools/api/resource.py
        rbtools/api/cache.py
    
    
  2. 
      
chipx86
  1. Ship It!
  2. 
      
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to master (87818c9).

Loading...