cubicweb #3610472 fix adjust_sys_path() implementation [open]

CubicWebConfiguration.adjust_sys_path() inserts apphome to sys.path (cf. ) and it has side effects on all the registry construction.

Consider the following layout in your cube:


The adjust_sys_path() mentioned above will insert cubes/mycube in sys.path. Later, when modules are loaded to build the registry, logilab.common.modutils will therefore load as views.file1 rather than cubes.mycube.views.file1. But at this point, if file2 is loaded and imports file1 with the following (expected) statement:

from cubes.mycube.views.file1 import foo

file1 will be reimported rather than picked in sys.modules cache leading to potential class duplicates and inconsistencies

done in<not specified>
load left0.500
closed by<not specified>