Skip to content

Commit

Permalink
Do not reload the vsc modules by default
Browse files Browse the repository at this point in the history
  • Loading branch information
stdweird committed Oct 12, 2015
1 parent 83e8dc4 commit 6d8595a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
9 changes: 7 additions & 2 deletions lib/vsc/install/shared_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@
URL_GH_HPCUGENT = 'https://github.com/hpcugent/%(name)s'
URL_GHUGENT_HPCUGENT = 'https://github.ugent.be/hpcugent/%(name)s'

RELOAD_VSC_MODS = False

def find_extra_sdist_files():
"""Looks for files to append to the FileList that is used by the egg_info."""
Expand Down Expand Up @@ -315,7 +316,10 @@ def reload_vsc_modules(self):

# reimport
for name in reload_vsc_modules:
__import__(name)
try:
__import__(name)
except ImportError:
log.error('Failed to reload/import %s (sys.path %s). Continuing, fingers crossed.' % (name, sys.path))

def force_xmlrunner(self):
"""
Expand Down Expand Up @@ -367,7 +371,8 @@ def run_tests(self):

cleanup = self.setup_sys_path()

self.reload_vsc_modules()
if RELOAD_VSC_MODS:
self.reload_vsc_modules()

res = TestCommand.run_tests(self)

Expand Down
4 changes: 3 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,12 @@ def remove_bdist_rpm_source_file():

shared_setup.remove_extra_bdist_rpm_files = remove_bdist_rpm_source_file

# Re-reload the vsc modules that vsc-base ships
shared_setup.RELOAD_VSC_MODS = True

PACKAGE = {
'name': 'vsc-base',
'version': '2.4.1',
'version': '2.4.2',
'author': [sdw, jt, ag, kh],
'maintainer': [sdw, jt, ag, kh],
'packages': ['vsc', 'vsc.install', 'vsc.utils'],
Expand Down

0 comments on commit 6d8595a

Please sign in to comment.