murano-pkg-check fails to build with mock > 4.0.0

Bug #1980254 reported by Joel Capitao
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Murano
Fix Released
Undecided
Unassigned

Bug Description

While rebuilding python-murano-pkg-check 0.3.0 on Fedora rawhide, we're hitting the issue below.

python3-mock-4.0.3-4.fc37.noarch

I suspect it's due to mock > 4.0.0

======================================================================
FAIL: muranopkgcheck.tests.test_manager.ManagerTest.test_validate
tags: worker-6
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/mock/mock.py", line 1343, in patched
    with self.decoration_helper(patched,
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/contextlib.py", line 137, in __enter__
    return next(self.gen)
           ^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/mock/mock.py", line 1325, in decoration_helper
    arg = exit_stack.enter_context(patching)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/contextlib.py", line 502, in enter_context
    result = _enter(cm)
             ^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/mock/mock.py", line 1437, in __enter__
    if spec is None and _is_async_obj(original):
                        ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/mock/mock.py", line 52, in _is_async_obj
    if hasattr(obj, '__func__'):
       ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/murano-pkg-check-0.3.0/muranopkgcheck/error.py", line 67, in __getattr__
    raise ValueError(_LE('Error {} was not registered').format(code))
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: Error __func__ was not registered
Ran 151 tests in 10.566s

Revision history for this message
Joel Capitao (jcapitao) wrote :
Revision history for this message
Joel Capitao (jcapitao) wrote :
Changed in murano:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.