Closed Bug 927670 Opened 6 years ago Closed 6 years ago

jit_test.py may not run due to conflicting progressbar.py on ubuntu

Categories

(Core :: JavaScript Engine, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla27

People

(Reporter: bkelly, Unassigned)

Details

Attachments

(1 file)

On my ubuntu development machine I get the following when I try to run the jit_test.py:

  bkelly@lenir:/srv/mozilla-central/js/src$ python jit-test/jit_test.py ../../obj-x86_64-unknown-linux-gnu/dist/bin/js
  Traceback (most recent call last):
    File "jit-test/jit_test.py", line 17, in <module>
      import jittests
    File "/srv/mozilla-central/js/src/tests/lib/jittests.py", line 23, in <module>
      from progressbar import ProgressBar, NullProgressBar
  ImportError: cannot import name NullProgressBar

This appears to be caused by a conflicting progressbar.py in one of the installed ubuntu modules.

To avoid this sort of thing the jit_test.py module could prepend its library directories to sys.path instead of appending.
Here is the fix I used to deal with the issue on my ubuntu machine.  It just switches from appending to prepending when updating sys.path.
Attachment #818157 - Flags: review?(jorendorff)
Comment on attachment 818157 [details] [diff] [review]
jit-test-prepend.patch

Review of attachment 818157 [details] [diff] [review]:
-----------------------------------------------------------------

Nice, thanks! r=me
Attachment #818157 - Flags: review?(jorendorff) → review+
Keywords: checkin-needed
Summary: jit_test.py may not run to conflicting progressbar.py on ubuntu → jit_test.py may not run due to conflicting progressbar.py on ubuntu
Component: JavaScript Engine: JIT → JavaScript Engine
https://hg.mozilla.org/mozilla-central/rev/98620827025c
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
You need to log in before you can comment on or make changes to this bug.