This is an archive of the discontinued Mercurial Phabricator instance.

py3: convert content-type to bytes
ClosedPublic

Authored by indygreg on Feb 11 2018, 5:57 PM.

Details

Summary

This fixes the exception:

TypeError: %b requires a bytes-like object, or an object that
implements __bytes__, not 'str'

On the line:

ui.debug('Content-Type: %s\n' % content_type)

And it prevents additional exceptions that use the content_type
variable later.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

indygreg created this revision.Feb 11 2018, 5:57 PM
This revision was automatically updated to reflect the committed changes.