[Freeipa-devel] [PATCH] 0001 six.u function instead of the decode

Ariel Barria ariel.o.barria at gmail.com
Thu Jul 28 16:29:07 UTC 2016


2016-07-28 7:10 GMT-05:00 Petr Spacek <pspacek at redhat.com>:
> On 27.7.2016 18:26, Ariel Barria wrote:
>> 2016-07-26 9:39 GMT-05:00 Petr Spacek <pspacek at redhat.com>:
>>> On 26.7.2016 16:28, Jan Cholasta wrote:
>>>> Hi,
>>>>
>>>> On 26.7.2016 16:09, Martin Basti wrote:
>>>>>
>>>>>
>>>>> On 22.07.2016 00:14, Ariel Barria wrote:
>>>>>> Hello everyone.
>>>>>>
>>>>>> I send patch for review.
>>>>
>>>> NACK, six.u() is supposed to be used on string literals *only* [1].
>>>>
>>>> A proper fix would be something like:
>>>>
>>>>     value = self.to_text()
>>>>     if not isinstance(value, unicode):
>>>>         value = value.decode('ascii')
>>>>     return value
>>
>> thanks for the guidance and comments
>>
>>>
>>> Most importantly, we should fix/provide this method in python-dns and inherit
>>> this method from there.
>>
>> Well, I made a pr, but apparently travis ci test failed with other
>> versions of python, so it is possible that they do not approve, I will
>> be performing other tests to see what the downside.
>>
>> https://github.com/rthalley/dnspython/pull/195
>
> Looking at the PR, there are functions
> dns.name.to_text()
> dns.name.to_unicode()
>
> What is missing in them?
>
> Petr^2 Spacek
>
>
>>>>> I will look on this, for some reason we received your e-mail just today
>>>>> (2016-07-26)
>>
>> welcome.
>> it was my mistake, I sent the patch to the list before being signed to the list
>>
>>>>
>>>> Honza
>>>>
>>>> [1] <https://pythonhosted.org/six/#six.u>
> --
> Petr^2 Spacek

Hi.
I send the requested changes
thanks for review.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: freeipa-arielb-0001-0002-six.u-function-instead-of-t.patch
Type: text/x-patch
Size: 1288 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20160728/bec00d88/attachment.bin>


More information about the Freeipa-devel mailing list