Re: [PATCH v2 04/14] git-p4: encode/decode communication with p4 for python3

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Yang Zhao <yang.zhao@xxxxxxxxxxxxxx> writes:

> The marshalled dict in the response given on STDOUT by p4 uses `str` for
> keys and string values. When run using python3, these values are
> deserialized as `bytes`, leading to a whole host of problems as the rest
> of the code assumes `str` is used throughout.
>
> This patch changes the deserialization behaviour such that, as much as
> possible, text output from p4 is decoded to native unicode strings.
> Exceptions are made for the field `data` as it is usually arbitrary
> binary data. `depotFile[0-9]*`, `path`, and `clientFile` are also exempt
> as they contain path strings not encoded with UTF-8, and must survive
> survive round-trip back to p4.

Doubled "survive"; will drop one of them while queuing.



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux