Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 915614 - =net-misc/yt-dlp-2023.09.24 fails tests when FEATURES=distcc
Summary: =net-misc/yt-dlp-2023.09.24 fails tests when FEATURES=distcc
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Ionen Wolkens
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-10-12 00:58 UTC by Jonathan Lovelace
Modified: 2023-10-12 05:25 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
net-misc:yt-dlp-2023.09.24:20231011-235334.log (net-misc:yt-dlp-2023.09.24:20231011-235334.log,673.29 KB, text/plain)
2023-10-12 00:58 UTC, Jonathan Lovelace
Details
emerge-info.txt (emerge-info.txt,8.74 KB, text/plain)
2023-10-12 00:58 UTC, Jonathan Lovelace
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Lovelace 2023-10-12 00:58:25 UTC
Created attachment 872595 [details]
net-misc:yt-dlp-2023.09.24:20231011-235334.log

==net-misc/yt-dlp-2023.09.24 fails the test TestYoutubeDLNetworking.test_proxy. The error output suggests that the failure is caused by Portage's integration of distcc:

______________________________________________________________ TestYoutubeDLNetworking.test_proxy[None-expected2] ______________________________________________________________

self = <test.test_networking.TestYoutubeDLNetworking object at 0x7ff23b58bb90>, proxy = None, expected = {'http': 'http://127.0.0.1:8081', 'https': 'http://127.0.0.1:8081'}

    @pytest.mark.parametrize('proxy,expected', [
        ('http://127.0.0.1:8080', {'all': 'http://127.0.0.1:8080'}),
        ('', {'all': '__noproxy__'}),
        (None, {'http': 'http://127.0.0.1:8081', 'https': 'http://127.0.0.1:8081'})  # env, set https
    ])
    def test_proxy(self, proxy, expected):
        old_http_proxy = os.environ.get('HTTP_PROXY')
        try:
            os.environ['HTTP_PROXY'] = 'http://127.0.0.1:8081'  # ensure that provided proxies override env
            with FakeYDL({'proxy': proxy}) as ydl:
>               assert ydl.proxies == expected
E               AssertionError: assert {'distcc_socks': '/var/tmp/portage/.portage.19807.net.sock', 'portage_socks5': '/var/tmp/portage/.portage.19807.net.sock', 'http': 'http:
//127.0.0.1:8081', 'https': 'http://127.0.0.1:8081'} == {'http': 'http://127.0.0.1:8081', 'https': 'http://127.0.0.1:8081'}
E                 Common items:
E                 {'http': 'http://127.0.0.1:8081', 'https': 'http://127.0.0.1:8081'}
E                 Left contains 2 more items:
E                 {'distcc_socks': '/var/tmp/portage/.portage.19807.net.sock',
E                  'portage_socks5': '/var/tmp/portage/.portage.19807.net.sock'}
E                 Full diff:
E                   {
E                 +  'distcc_socks': '/var/tmp/portage/.portage.19807.net.sock',
E                    'http': 'http://127.0.0.1:8081',
E                    'https': 'http://127.0.0.1:8081',
E                 +  'portage_socks5': '/var/tmp/portage/.portage.19807.net.sock',
E                   }

expected   = {'http': 'http://127.0.0.1:8081', 'https': 'http://127.0.0.1:8081'}
old_http_proxy = 'http://127.0.0.1:8081'
proxy      = None
self       = <test.test_networking.TestYoutubeDLNetworking object at 0x7ff23b58bb90>
ydl        = <test.helper.FakeYDL object at 0x7ff23b9de990>

test/test_networking.py:1104: AssertionError
Comment 1 Jonathan Lovelace 2023-10-12 00:58:55 UTC
Created attachment 872596 [details]
emerge-info.txt
Comment 2 Larry the Git Cow gentoo-dev 2023-10-12 05:25:04 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5f8ed297d3d88da5bd1f71524afe18ed3f59bd74

commit 5f8ed297d3d88da5bd1f71524afe18ed3f59bd74
Author:     Ionen Wolkens <ionen@gentoo.org>
AuthorDate: 2023-10-12 05:07:15 +0000
Commit:     Ionen Wolkens <ionen@gentoo.org>
CommitDate: 2023-10-12 05:24:06 +0000

    net-misc/yt-dlp: skip failing proxy test with FEATUERS=distcc
    
    This test is not worth finding workarounds or doing
    conditions, just skip it.
    
    Closes: https://bugs.gentoo.org/915614
    Signed-off-by: Ionen Wolkens <ionen@gentoo.org>

 net-misc/yt-dlp/yt-dlp-2023.09.24.ebuild | 5 +++++
 net-misc/yt-dlp/yt-dlp-2023.10.07.ebuild | 5 +++++
 net-misc/yt-dlp/yt-dlp-9999.ebuild       | 5 +++++
 3 files changed, 15 insertions(+)