Skip to content

put fake 'vsc' namespace in place that produces an error on import#2790

Merged
vanzod merged 1 commit intoeasybuilders:4.xfrom
boegel:fake_vsc
Feb 27, 2019
Merged

put fake 'vsc' namespace in place that produces an error on import#2790
vanzod merged 1 commit intoeasybuilders:4.xfrom
boegel:fake_vsc

Conversation

@boegel
Copy link
Copy Markdown
Member

@boegel boegel commented Feb 27, 2019

Since we ingested vsc-base & vsc-install into the EasyBuild framework (cfr. #2708) we should actively prevent imports from the vsc.* namespace, since it can cause problems (see for example #2745).

This injects a fake vsc namespace early on, that catches any import vsc.* or from vsc.* import ... statements, and exits with a clear error, for example:

$ eb GCCcore-6.3.0.eb
== temporary log file in case of crash /tmp/eb-c1eTh9/easybuild-yR5zsp.log

ERROR: Detected import from 'vsc' namespace in /Users/kehoste/work/easybuild-easyblocks/easybuild/easyblocks/g/gcc.py (line 42)
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.

@boegel boegel added this to the 4.0 milestone Feb 27, 2019
@vanzod vanzod merged commit 50d7bfa into easybuilders:4.x Feb 27, 2019
@boegel boegel deleted the fake_vsc branch February 27, 2019 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants