[PATCH 3 of 3 in crew] run-tests: use correct python safely under --jobs
Adrian Buehlmann
adrian at cadifra.com
Wed Dec 12 12:41:52 UTC 2012
On 2012-12-12 02:35, Siddharth Agarwal wrote:
> Unfortunately it seems the trick of copying the python executable into
> the hg directory doesn't work on Windows, because Windows Python depends
> on other files in its own directory to work.
This is not entirely true, as at least a globally installed Python on
Windows will have the required dll's installed in a system directory and
should thus find them (and its other required files).
At least it does find them here (Windows 7 x64).
The tests pass here in MSYS using fe5a41144982 with:
$ PATH="/mingw/bin:/bin:`pwd`/..:/c/python:/c/python/scripts" python
run-tests.py --local
Two tests are currently failing here:
--- C:\Users\adi\hgrepos\hg-main\tests\test-install.t
+++ C:\Users\adi\hgrepos\hg-main\tests\test-install.t.err
@@ -1,7 +1,7 @@
hg debuginstall
$ hg debuginstall
checking encoding (ascii)...
- checking Python lib (*lib*)... (glob)
+ checking Python lib (C:\Python27_x64\Lib)...
checking installed modules (*mercurial)... (glob)
checking templates (*mercurial?templates)... (glob)
checking commit editor...
@@ -11,7 +11,7 @@
hg debuginstall with no username
$ HGUSER= hg debuginstall
checking encoding (ascii)...
- checking Python lib (*lib*)... (glob)
+ checking Python lib (C:\Python27_x64\Lib)...
checking installed modules (*mercurial)... (glob)
checking templates (*mercurial?templates)... (glob)
checking commit editor...
--- C:\Users\adi\hgrepos\hg-main\tests\test-rebase-pull.t
+++ C:\Users\adi\hgrepos\hg-main\tests\test-rebase-pull.t.err
@@ -144,7 +144,7 @@
adding L1
created new head
$ hg pull --rev tip --rebase
- pulling from $TESTTMP/a
+ pulling from $TESTTMP\a
searching for changes
adding changesets
adding manifests
After the test, I see that there is a python.exe in the repo root.
And Microsoft's Windows "firewall" popped up alerting me that this
python.exe newly wants to start listening on some ports (which I
acknowledged).
> Mads suggested we make sure
> os.path.join(dirname(sys.executable), "python.exe") existed, and then
> add that directory to the path.
I haven't investigated enough to comment on that.
But copying the python.exe feels indeed a bit strange on first thought here.
More information about the Mercurial-devel
mailing list