The first call to ./mach build -r
fails with:
Traceback (most recent call last):
File "./mach", line 103, in <module>
main(sys.argv)
File "./mach", line 33, in main
mach = mach_bootstrap.bootstrap(topdir)
File "/workspace/servo/python/mach_bootstrap.py", line 288, in bootstrap
import mach.main
ImportError: No module named mach.main
but when you try again, it works.
Thanks to a suggestion from @SimonSapin, I logged sys.path
just before /workspace/servo/python/mach_bootstrap.py:288
, which revealed this difference between the two runs:
--- one.txt 2019-06-28 16:04:52.083072743 +0000
+++ two.txt 2019-06-28 16:15:27.118086735 +0000
@@ -10,17 +10,15 @@
u'/workspace/servo/python',
'/workspace/servo',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python27.zip',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python2.7',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python2.7/plat-linux2',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python2.7/lib-tk',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python2.7/lib-old',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python2.7/lib-dynload',
+ '/workspace/.pip-modules/lib/python2.7/site-packages',
+ '/workspace/servo/python/tidy',
'/home/gitpod/.pyenv/versions/2.7.15/lib/python2.7/site-packages']
-Traceback (most recent call last):
- File "./mach", line 103, in <module>
- main(sys.argv)
- File "./mach", line 33, in main
- mach = mach_bootstrap.bootstrap(topdir)
- File "/workspace/servo/python/mach_bootstrap.py", line 290, in bootstrap
- import mach.main
-ImportError: No module named mach.main
+info: syncing channel updates for 'nightly-2019-05-14-x86_64-unknown-linux-gnu'
+info: latest update on 2019-05-14, rust version 1.36.0-nightly (a9ec99f42 2019-05-13)
+info: downloading component 'rustc'
+^Cmach interrupted by signal or user action. Stopping.
\ No newline at end of file
As you can see, the run that fails is missing '/workspace/.pip-modules/lib/python2.7/site-packages'
and '/workspace/servo/python/tidy'
in sys.path
, while the next run that has them works.
I wonder why the first round is missing these. Maybe it's a race condition, related to how Gitpod initializes /workspace/.pip-modules
?