Xqt created this task.
Xqt added projects: Pywikibot, Pywikibot-tests.
Restricted Application added subscribers: pywikibot-bugs-list, Aklapper.

TASK DESCRIPTION
  pywikibot CI github action tests fails for pypy3.10
  
    ======================================================================
    ERROR: test_html_comparator (tests.diff_tests.TestNoBeautifulSoup)
    Test html_comparator when bs4 not installed.
    ----------------------------------------------------------------------
    Traceback (most recent call last):
      File 
"/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py", line 
1379, in patched
        return func(*newargs, **newkeywargs)
      File "/home/runner/work/pywikibot/pywikibot/tests/diff_tests.py", line 
96, in test_html_comparator
        with self.assertRaises(ImportError):
      File 
"/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/site-packages/coverage/pytracer.py",
 line 258, in _trace
        cast(set[TLineNo], self.cur_file_data).add(flineno)
      File "<string>", line 3, in __import__
      File 
"/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py", line 
1114, in __call__
        return self._mock_call(*args, **kwargs)
      File 
"/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py", line 
1118, in _mock_call
        return self._execute_mock_call(*args, **kwargs)
      File 
"/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py", line 
1173, in _execute_mock_call
        raise effect
    ImportError
  
  
  
    =================================== FAILURES 
===================================
    ___________________ TestNoBeautifulSoup.test_html_comparator 
___________________
    
    self = <tests.diff_tests.TestNoBeautifulSoup 
testMethod=test_html_comparator>
    mocked_import = <function __import__ at 0x0000000002b7b9c0>
    
        def test_html_comparator(self, mocked_import):
            """Test html_comparator when bs4 not installed."""
    >       with self.assertRaises(ImportError):
    
    tests/diff_tests.py:96: 
    _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ 
    
/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/site-packages/coverage/pytracer.py:258:
 in _trace
        cast(set[TLineNo], self.cur_file_data).add(flineno)
    <string>:3: in __import__
        ???
    /opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py:1114: 
in __call__
        return self._mock_call(*args, **kwargs)
    /opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py:1118: 
in _mock_call
        return self._execute_mock_call(*args, **kwargs)
    _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ 
    
    self = <MagicMock name='__import__' spec='function' id='203967752'>
    args = ('_pypy_generic_alias',), kwargs = {}, effect = <class 'ImportError'>
    
        def _execute_mock_call(self, /, *args, **kwargs):
            # separate from _increment_mock_call so that awaited functions are
            # executed separately from their call, also AsyncMock overrides 
this method
        
            effect = self.side_effect
            if effect is not None:
                if _is_exception(effect):
    >               raise effect
    E               ImportError
    
    /opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/unittest/mock.py:1173: 
ImportError
    _________________________ TestTkdialog.test_tk_dialog 
__________________________
    
    self = <tests.gui_tests.TestTkdialog testMethod=test_tk_dialog>
    
        def test_tk_dialog(self):
            """Test Tk dialog."""
            desc = 'foo'
            filename = 'MP_sounds.png'
            image = f'tests/data/images/{filename}'
    >       box = Tkdialog(desc, image, filename)
    
    tests/gui_tests.py:30: 
    _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ 
    pywikibot/userinterfaces/gui.py:467: in __init__
        self.root = tkinter.Tk()
    
/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/tkinter/__init__.py:2306: in 
__init__
        self._loadtk()
    _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ 
    
    self = <tkinter.Tk object .>
    
        def _loadtk(self):
            self._tkloaded = True
            global _default_root
            # Version sanity checks
            tk_version = self.tk.getvar('tk_version')
            if tk_version != _tkinter.TK_VERSION:
    >           raise RuntimeError("tk.h version (%s) doesn't match libtk.a 
version (%s)"
                                   % (_tkinter.TK_VERSION, tk_version))
    E           RuntimeError: tk.h version (8.6) doesn't match libtk.a version 
(8.5)
    
    
/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/tkinter/__init__.py:2322: 
RuntimeError
    ___________________________ TestTkinter.test_tkinter 
___________________________
    
    self = <tests.gui_tests.TestTkinter testMethod=test_tkinter>
    
        def test_tkinter(self):
            """Test Tkinter window."""
    >       root = tkinter.Tk()
    
    tests/gui_tests.py:48: 
    _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ 
    
/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/tkinter/__init__.py:2306: in 
__init__
        self._loadtk()
    _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ 
    
    self = <tkinter.Tk object .>
    
        def _loadtk(self):
            self._tkloaded = True
            global _default_root
            # Version sanity checks
            tk_version = self.tk.getvar('tk_version')
            if tk_version != _tkinter.TK_VERSION:
    >           raise RuntimeError("tk.h version (%s) doesn't match libtk.a 
version (%s)"
                                   % (_tkinter.TK_VERSION, tk_version))
    E           RuntimeError: tk.h version (8.6) doesn't match libtk.a version 
(8.5)
    
    
/opt/hostedtoolcache/PyPy/3.10.14/x64/lib/pypy3.10/tkinter/__init__.py:2322: 
RuntimeError
  
  The underlying problem might be `RuntimeError: tk.h version (8.6) doesn't 
match libtk.a version (8.5)`

TASK DETAIL
  https://phabricator.wikimedia.org/T380732

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Xqt
Cc: Aklapper, pywikibot-bugs-list, Xqt, mevo, PotsdamLamb, Jyoo1011, 
JohnsonLee01, SHEKH, Dijkstra, Khutuck, Zkhalido, Aram, Viztor, Wenyi, Tbscho, 
MayS, Mdupont, JJMC89, Dvorapa, Altostratus, binbot, Avicennasis, mys_721tx, 
jayvdb, Masti, Alchimista
_______________________________________________
pywikibot-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to