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

Bug#894163: RFS: streamlink/0.11.0+dfsg-1~bpo9+1



Le 28/03/2018 à 03:46, Paul Wise a écrit :
> On Tue, 2018-03-27 at 22:49 +0200, Alexis Murzeau wrote:
> 
>> Can you post your logs ?
> 
> Attached.
> 
>> I cannot reproduce this error either with sbuild or pbuilder.
> 
> I guess the LANG/LC_ALL in your chroots has UTF-8 in the name,
> for some reason mine only has LANG=C LC_ALL=C.
> 
> Strangely, the RB infra builds fine with LANG=C LC_ALL=C:
> 
> https://tests.reproducible-builds.org/debian/rb-pkg/unstable/amd64/streamlink.html
> 
>> I previously encountered this encoding error and it should have been fixed
>> by debian/patches/0006-Avoid-use-of-non-ASCII-in-plugins.patch.
> 
> You only patched one of the UTF-8 files, not all of them:
> 
> $ file src/streamlink/plugins/* | grep -v ASCII
> src/streamlink/plugins/showroom.py:               Python script, UTF-8 Unicode text executable
> 
> This file includes some Chinese characters in the keys of a dict,
> so I don't think you will be able to patch them out.
> 
> $ grep -C3 --color='auto' -P -n "[^\x00-\x7F]" src/streamlink/plugins/showroom.py
> 42-
> 43-# the "low latency" streams are rtmp, the others are hls
> 44-_rtmp_quality_lookup = {
> 45:    "オリジナル画質": "high",
> 46:    "オリジナル画質(低遅延)": "high",
> 47-    "original spec(low latency)": "high",
> 48-    "original spec": "high",
> 49:    "低画質": "low",
> 50:    "低画質(低遅延)": "low",
> 51-    "low spec(low latency)": "low",
> 52-    "low spec": "low"
> 53-}
> 
> So upstream needs to load the plugin files using the UTF-8 encoding.
> 

I think I have found the cause.
I found that the failing test was loading python modules using
imp.load_module with possibly closed file descriptor.
In that case, python reopen the file descriptor using open() which use
the system encoding by default (here, ASCII).

This does not always happen reliably and I'm not sure why, but I think
this the reason we have not the same test behavior.

I've replaced the patch 0006-Avoid-use-of-non-ASCII-in-plugins.patch
with another patch ensuring load_module is given an open file descriptor.

I've uploaded the resulting package on mentors.debian.net.
Does it work for you ? Thanks :)

dget
https://mentors.debian.net/debian/pool/main/s/streamlink/streamlink_0.11.0+dfsg-1~bpo9+1.dsc


PS: Note that this uploaded package does not contain the build twice in
a row fix.

-- 
Alexis Murzeau
PGP: B7E6 0EBB 9293 7B06 BDBC  2787 E7BD 1904 F480 937F

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: