Dear William,
On 10/12/2019 19:15, William Brown wrote:
I suspect that I am missing something here….
I wanted to upgrade from 4.0.0 to 4.1.0 so I tried first
$ eb --install-latest-eb-release
..which failed with:
== postprocessing...
== sanity checking...
ERROR: Detected import from 'vsc' namespace in
/usr/lib64/python2.7/pkgutil.py (line 246)
vsc-base & vsc-install were ingested into the EasyBuild framework in
EasyBuild v4.0
The functionality you need may be available in the 'easybuild.base.*'
namespace.
It seems like you have vsc-base installed system-wide, and EasyBuild is
tripping over that during the sanity check...
The vsc import check is done to ensure you're not still using "import
vsc" in any of the additional Python modules you're using with EasyBuild
(via --include-* or via --hooks, for example).
EasyBuild 4.x catches any imports from the 'vsc' namespace, and produces
the error you've hit.
In this case though, it seems like the import of the vsc namespace is
done by Python itself, so that's backfiring now...
One thing you could try is to get rid of the system-wide installation of
vsc-base, if that's an option (it's useless anyway for EasyBuild 4.x).
I'll look into making the vsc import check a bit less strict, but that
won't do you much good now (since the problem is in the EasyBuild v4.0.0
installation you're using to install EasyBuild v4.1.0).
A workaround you could try is to use EasyBuild v3.9.4 to run "eb
--install-latest-eb-release", if you have that installed (older 3.x
versions won't work to install EasyBuild 4.x though).
If you don't have EasyBuild v3.9.4 installed, you could temporarily
install it using "pip install --prefix /tmp/eb394 easybuild==3.9.4", so
you can use that to install EasyBuild v4.1.0.
An alternative (perhaps more desperate/ugly) workaround is to
(temporarily) tweak your EasyBuild v4.0.0 installation, by commenting
out the "sys.exit(1)" in the install_fake_vsc function in
easybuild/tools/filetools.py.
If you then try "eb --install-latest-eb-release", you'll still see the
errors being printed, but they won't be fatal, and the v4.1.0
installation should hopefully complete.
Do let me know if that helps at all...
So I decided to go back to bootstrapping EasyBuild, although using the
same EASYBUILDPREFIX path as my exiting installation (as I don’t really
want to have to migrate the contents).
That's fine, you can use the bootstrap procedure in an existing software
stack, all it really does is install EasyBuild in a temporary location,
and then use that EasyBuild installation to install EasyBuild in the
specified location. It doesn't care at all if other modules are already
installed there (and it won't touch them either).
That also fails…
[[INFO]] running post install command 'easy_install --upgrade
--prefix=/tmp/tmpOqoOOs/eb_stage1 vsc-base<2.9.0'
Traceback (most recent call last):
File "bootstrap_eb.py", line 1124, in <module>
main()
File "bootstrap_eb.py", line 916, in main
templates = stage1(tmpdir, sourcepath, distribute_egg_dir,
forcedversion)
File "bootstrap_eb.py", line 635, in stage1
import vsc.utils.fancylogger
ImportError: No module named utils.fancylogger
Looking in the bootstrap_eb.py file it does indeed contain 'import
vsc.utils.fancylogger'. Reading back in older discussions I get the
impression that vsc.utils was being replaced.
Indeed, we (still) haven't cleaned up the bootstrap script to get rid of
the stuff it's using from vsc-base. That's just one of the issues with
it, there's others...
This issue is a bit puzzling though. Why is the import from the 'vsc'
namespace failing, while the bootstrap script still installs vsc-base?
Do you have a broken system-wide vsc-base installation perhaps?
This could also explain while you're having the issues with updating to
v4.1.0 using v4.0.0 while others don't.
I must have missed something as on another system I upgraded from 4.0.1
to 4.1.0 without issue. Both are CentOS 7, and the system Python is the
same 2.7.5.
I guess the other system never had a system-wide vsc-base installation?
regards,
Kenneth
William
*William Brown*
Systems Administrator
*RCSI* Information Technology
Royal College of Surgeons in Ireland
Building 121 St Stephens Green, IT dept
*T: *015720012
*E: *williambr...@rcsi.ie *W: *www.rcsi.com <http://www.rcsi.com/>
/Transforming Healthcare Education, Research and Service: RCSI Strategic
Plan 2018-2022 <http://www.rcsi.ie/strategy2018>/