spurious test failures regarding LPModerate and XMLRPCRunner

Bug #683486 reported by Martin Pool
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
Undecided
Martin Pool

Bug Description

Running './bin/test -t mail' in a recent branch of Launchpad produces the following spurious failures:

https://lists.launchpad.net/launchpad-dev/msg05846.html

mbp@lp-lucid% ./bin/test -t incoming
Test-module import failures:

Module: lp.services.mailman.tests.test_lpmoderate

Traceback (most recent call last):
  File "/home/mbp/launchpad/lp-branches/work/lib/lp/scripts/utilities/importfascist.py", line 190, in import_fascist
    module = original_import(name, globals, locals, fromlist, level)
  File "/home/mbp/launchpad/lp-branches/work/lib/lp/services/mailman/tests/test_lpmoderate.py", line 9, in <module>
    from Mailman.Handlers import LPModerate
ImportError: cannot import name LPModerate

Module: lp.services.mailman.tests.test_mailman

Traceback (most recent call last):
  File "/home/mbp/launchpad/lp-branches/work/lib/lp/scripts/utilities/importfascist.py", line 190, in import_fascist
    module = original_import(name, globals, locals, fromlist, level)
  File "/home/mbp/launchpad/lp-branches/work/lib/lp/services/mailman/tests/test_mailman.py", line 28, in <module>
    from lp.services.mailman.testing import helpers
  File "/home/mbp/launchpad/lp-branches/work/lib/lp/scripts/utilities/importfascist.py", line 190, in import_fascist
    module = original_import(name, globals, locals, fromlist, level)
  File "/home/mbp/launchpad/lp-branches/work/lib/lp/services/mailman/testing/__init__.py", line 19, in <module>
    from Mailman.Queue import XMLRPCRunner
ImportError: cannot import name XMLRPCRunner

This made me miss some other actually important failures in testing lp:~mbp/launchpad/dkim

Related branches

Revision history for this message
Martin Pool (mbp) wrote :

The problem seems to be that lp.services.mailman.monkeypatches.monkey_patch() has not been run. Despite the name, this doesn't monkey patch in the usual Python sense by tweaking in-memory structures, but rather it patches a mailman source tree.

This is called by ./buildmailman.py and also lp/services/mailman/runmailman.py. I guess my tree should have had the former run, but it has not.

I think the reason behind _that_ may be that 'make compile' has some declared dependencies but they may not be enough to make sure it runs. I wonder how I ever got a mailman tree that wasn't patched though.

Revision history for this message
Martin Pool (mbp) wrote :

No, even when buildmailman runs the same problems occur.

affects: launchpad → launchpad-registry
Martin Pool (mbp)
tags: added: qa-untestable
Revision history for this message
Martin Pool (mbp) wrote :
Revision history for this message
Launchpad QA Bot (lpqabot) wrote : Bug fixed by a commit

Fixed in stable r12118 (http://bazaar.launchpad.net/~launchpad-pqm/launchpad/stable/revision/12118) by a commit, but not testable.

Changed in launchpad:
status: In Progress → Fix Committed
Curtis Hovey (sinzui)
Changed in launchpad:
status: Fix Committed → Fix Released
Curtis Hovey (sinzui)
Changed in launchpad:
milestone: none → 11.01
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.