This is an archive of the discontinued Mercurial Phabricator instance.

py3: fix keyword arguments handling in mq
ClosedPublic

Authored by pulkit on Oct 5 2017, 8:20 PM.

Details

Summary

This patch fixes the handling of keyword arguments to functions on Python 3. On
python3, the keys of keyword arguments need to str which is unicode. So any
keyword argument will get will have str keys and any dictionary we pass as
kwargs must have all the keys as str.

This patch uses pycompat.(strkwargs|byteskwargs) to do so conversion between
bytes keys and str keys and use r'' if there are very less uses and conversion
can be prevented.

Diff Detail

Repository
rHG Mercurial
Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

pulkit created this revision.Oct 5 2017, 8:20 PM
This revision was automatically updated to reflect the committed changes.