Closed Bug 753190 Opened 14 years ago Closed 14 years ago

Specifying --restart using Mozmill 2.0 (master) causes an exception in mozprofile

Categories

(Testing :: Mozbase, defect)

defect
Not set
major

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: davehunt, Assigned: k0scist)

References

Details

(Whiteboard: [mozmill-2.0+])

Attachments

(2 files)

Expected: Firefox restarts between each test. Actual: Firefox terminates testrun early. $ mozmill -m tests/l10n/manifest.ini -b /Applications/Firefox\ Beta.app/Contents/MacOS/firefox --restart INFO | *** nsHTMLElement::FinishDecoderSetup() mDecoder=0x1138df100 stream=0x113a22000 src=http://videos-cdn.mozilla.net/brand/Mozilla_Firefox_Manifesto_v0.2_640.webm INFO | TEST-UNEXPECTED-FAIL | Disconnect Error: Application unexpectedly closed INFO | Passed: 0 INFO | Failed: 0 INFO | Skipped: 0 ERROR | Traceback (most recent call last): ERROR | File "/Users/dhunt/workspace/mozmill/mozmill/mozmill/__init__.py", line 623, in run ERROR | runner.reset() # reset the profile ERROR | File "/Users/dhunt/.virtualenvs/mozmill-master/lib/python2.7/site-packages/mozrunner-5.2-py2.7.egg/mozrunner/runner.py", line 185, in reset ERROR | self.profile.reset() ERROR | File "/Users/dhunt/.virtualenvs/mozmill-master/lib/python2.7/site-packages/mozprofile-0.3.1-py2.7.egg/mozprofile/profile.py", line 98, in reset ERROR | proxy = self._proxy) ERROR | File "/Users/dhunt/.virtualenvs/mozmill-master/lib/python2.7/site-packages/mozprofile-0.3.1-py2.7.egg/mozprofile/profile.py", line 78, in __init__ ERROR | self.addon_manager.install_addons(addons, addon_manifests) ERROR | File "/Users/dhunt/.virtualenvs/mozmill-master/lib/python2.7/site-packages/mozprofile-0.3.1-py2.7.egg/mozprofile/addons.py", line 49, in install_addons ERROR | self.install_from_path(addon) ERROR | File "/Users/dhunt/.virtualenvs/mozmill-master/lib/python2.7/site-packages/mozprofile-0.3.1-py2.7.egg/mozprofile/addons.py", line 177, in install_from_path ERROR | assert os.path.isdir(path), "Addon '%s' cannot be installed" % path ERROR | AssertionError: Addon '/var/folders/5_/9gz0dv9s51q2shxc8hg62j200000gn/T/tmpQ_ExVB.mozrunner/extensions/mozmill@mozilla.com' cannot be installed
Blocks: 751848
Does it only happen when using manifests? What is the result by specifying -t?
So I have tested this and the same happens with the -t option. Looks like we are trying to access the extension folder of the profile from the formerly restart test. But the new one already got a new profile.
Severity: normal → major
Whiteboard: [mozmill-2.0+]
So the patch on bug 751348 caused this failure to appear but it's probably not the regressor. I have checked the initial version of Mozbase and it works fine. So one of the patches since then caused this bug.
First run tries to install the extensions from: INFO | ************ /Volumes/data/code/tools/mozmill/mozmill/mozmill/extension INFO | INFO | ************ /Volumes/data/code/tools/mozmill/jsbridge/jsbridge/extension INFO | After the restart we are trying to install from: INFO | ************ /Volumes/data/code/tools/mozmill/mozmill/mozmill/extension INFO | INFO | ************ /var/folders/wd/zmy4z7xn7wd7sjq90z1y52f80000gn/T/tmpfT3dcZ.mozrunner/extensions/mozmill@mozilla.com INFO | That means that at some point the installed folder of the first profile has been added to the list of to install extensions.
Actually we duplicate all the extensions with their installed location from the formerly profile: INFO | ['/Volumes/data/code/tools/mozmill/mozmill/mozmill/extension', u'/var/folders/wd/zmy4z7xn7wd7sjq90z1y52f80000gn/T/tmp5jvWsq.mozrunner/extensions/mozmill@mozilla.com', '/Volumes/data/code/tools/mozmill/jsbridge/jsbridge/extension', u'/var/folders/wd/zmy4z7xn7wd7sjq90z1y52f80000gn/T/tmp5jvWsq.mozrunner/extensions/jsbridge@mozilla.com']
Blocks: 751143
We actually have a test code that already catches this case, https://github.com/mozautomation/mozmill/blob/master/mutt/mutt/tests/python/testmultiplerun.py (which used to work). Now I get: (mozmill)│BROWSER_PATH=`which firefox` ./testmultiplerun.py LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/libtotem-cone-plugin.so [/usr/lib/mozilla/plugins/libtotem-cone-plugin.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/libtotem-gmp-plugin.so [/usr/lib/mozilla/plugins/libtotem-gmp-plugin.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/libtotem-narrowspace-plugin.so [/usr/lib/mozilla/plugins/libtotem-narrowspace-plugin.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/libtotem-mully-plugin.so [/usr/lib/mozilla/plugins/libtotem-mully-plugin.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/mplayerplug-in-wmp.so [/usr/lib/mozilla/plugins/mplayerplug-in-wmp.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/mplayerplug-in.so [/usr/lib/mozilla/plugins/mplayerplug-in.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /opt/google/talkplugin/libnpgtpo3dautoplugin.so [/opt/google/talkplugin/libnpgtpo3dautoplugin.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/mplayerplug-in-qt.so [/usr/lib/mozilla/plugins/mplayerplug-in-qt.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/mplayerplug-in-rm.so [/usr/lib/mozilla/plugins/mplayerplug-in-rm.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/mplayerplug-in-dvx.so [/usr/lib/mozilla/plugins/mplayerplug-in-dvx.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /usr/lib/mozilla/plugins/librhythmbox-itms-detection-plugin.so [/usr/lib/mozilla/plugins/librhythmbox-itms-detection-plugin.so: wrong ELF class: ELFCLASS64] LoadPlugin: failed to initialize shared library /opt/google/talkplugin/libnpgoogletalk.so [/opt/google/talkplugin/libnpgoogletalk.so: wrong ELF class: ELFCLASS64] F ====================================================================== FAIL: test_runtwice (__main__.TestMozmillAPI) ---------------------------------------------------------------------- Traceback (most recent call last): File "./testmultiplerun.py", line 24, in test_runtwice results = m.run(dict(path=path)) File "/home/jhammel/mozmill/src/mozmill/mozmill/mozmill/__init__.py", line 352, in run self.run_tests(*tests) File "/home/jhammel/mozmill/src/mozmill/mozmill/mozmill/__init__.py", line 319, in run_tests frame = self.start_runner() File "/home/jhammel/mozmill/src/mozmill/mozmill/mozmill/__init__.py", line 251, in start_runner self.runner.start() File "/home/jhammel/mozmill/src/mozbase/mozrunner/mozrunner/runner.py", line 162, in start self.profile.reset() File "/home/jhammel/mozmill/src/mozbase/mozprofile/mozprofile/profile.py", line 98, in reset proxy = self._proxy) File "/home/jhammel/mozmill/src/mozbase/mozprofile/mozprofile/profile.py", line 78, in __init__ self.addon_manager.install_addons(addons, addon_manifests) File "/home/jhammel/mozmill/src/mozbase/mozprofile/mozprofile/addons.py", line 49, in install_addons self.install_from_path(addon) File "/home/jhammel/mozmill/src/mozbase/mozprofile/mozprofile/addons.py", line 177, in install_from_path assert os.path.isdir(path), "Addon '%s' cannot be installed" % path AssertionError: Addon '/tmp/tmpRoW6Sc.mozrunner/extensions/mozmill@mozilla.com' cannot be installed ---------------------------------------------------------------------- Ran 1 test in 10.981s FAILED (failures=1)
The profile itself ceases to exist
Going ahead and attempting to tackle this
Assignee: nobody → jhammel
Attached patch hopeful fix — — Splinter Review
We were keeping track of the installed location of addons. Instead we should keep track of what is actually passed in
Attachment #625965 - Flags: review?(dburns)
This should be accompanied to a version bump for mozprofile and mozrunner
Comment on attachment 625965 [details] [diff] [review] hopeful fix Review of attachment 625965 [details] [diff] [review]: ----------------------------------------------------------------- looks good
Attachment #625965 - Flags: review?(dburns) → review+
pushed: https://github.com/mozilla/mozbase/commit/270a857328b130860d1b1b512e23899557a3c8f7 Will do the version bumps; Mozmill will need to pull in these deps
bumped mozprofile 0.3.2 and mozrunner 5.5 and released to pypi
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Attachment #625972 - Flags: review?(hskupin)
Attachment #625972 - Flags: review?(hskupin) → review+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: