Closed Bug 613268 Opened 14 years ago Closed 14 years ago

jsbridge and mozmill should probably have zip_safe=False

Categories

(Testing Graveyard :: Mozmill, defect)

defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: k0scist, Assigned: k0scist)

Details

(Whiteboard: [mozmill-1.5.2+])

Attachments

(2 files)

Our current model involves looking for real existent files versus setuptools virtual files.  The original reason for this was to enabled uninstalled running, which ABICT doesn't work.

"""
[adrian@localhost mozmill-tests]$ mozmill -b ../../Download/firefox-fr/firefox -t firefox/testLocalization/testPreferences.js --show-errors
Traceback (most recent call last):
  File "/usr/bin/mozmill", line 8, in <module>
    load_entry_point('mozmill==1.5.1', 'console_scripts', 'mozmill')()
  File "/usr/lib/python2.6/site-packages/mozmill-1.5.1-py2.6.egg/mozmill/__init__.py", line 811, in cli
    
  File "/usr/lib/python2.6/site-packages/mozmill-1.5.1-py2.6.egg/mozmill/__init__.py", line 752, in run
    
  File "/usr/lib/python2.6/site-packages/mozrunner-2.5.2-py2.6.egg/mozrunner/__init__.py", line 600, in create_runner
    
  File "/usr/lib/python2.6/site-packages/mozmill-1.5.1-py2.6.egg/mozmill/__init__.py", line 744, in get_profile
    
  File "/usr/lib/python2.6/site-packages/jsbridge-2.4.1-py2.6.egg/jsbridge/__init__.py", line 115, in get_profile
    
  File "/usr/lib/python2.6/site-packages/mozrunner-2.5.2-py2.6.egg/mozrunner/__init__.py", line 239, in install_addon
    
OSError: [Errno 20] Not a directory: '/usr/lib/python2.6/site-packages/jsbridge-2.4.1-py2.6.egg/jsbridge/extension'
"""
(from http://pastebin.mozilla.org/857600)

If we look at the code for install_addon, it requires the file must actually exist, which it won't for zipped eggs:  https://github.com/mozautomation/mozmill/blob/master/mozprofile/mozprofile/profile.py#L128

The eggs get zipped because zip_safe is not set to False in setup.py .  We should probably set this. That would be the quickest fix.  We should then up the version and reupload to pypi so that setuptools doesn't get confused.  The alternative approach is use setuptools resource_filename in the places we need files from the eggs.  IMHO, zipped eggs aren't very advantageous and are mostly a pain

https://github.com/mozautomation/mozmill/blob/master/jsbridge/setup.py
https://github.com/mozautomation/mozmill/blob/master/mozmill/setup.py
We can safely overwrite existing versions on pypi?
Assignee: nobody → jhammel
Status: NEW → ASSIGNED
Attachment #492406 - Flags: review?(fayearthur+bugs)
Attachment #492408 - Flags: review?(fayearthur+bugs)
Comment on attachment 492406 [details] [diff] [review]
zip_safe = False on hotfix-1.5.2

seems like a good idea.
Attachment #492406 - Flags: review?(fayearthur+bugs) → review+
Comment on attachment 492408 [details] [diff] [review]
zip_safe = False on master

also good
Attachment #492408 - Flags: review?(fayearthur+bugs) → review+
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Whiteboard: [mozmill-1.5.2+]
Verified fixed based on checkins.
Status: RESOLVED → VERIFIED
Product: Testing → Testing Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: