import error when compiling engine for windows

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By sandheaver
:warning: Old Version Published before Godot 3 was released.

Hi, I am experiencing the following import error when compiling the latest stable source code for windows (v.2.1.3) . I compiled the engine successfully several times last year with the same setup. Can anyone help me identify what might be missing or what I am doing wrong? Thanks.

:bust_in_silhouette: Reply From: sandheaver

I think I have found the answer myself.

I think at the point where the error is thrown, the SConstruct file is looping through the modules in c:\godot\modules , looking for the config.py file for each module:

for x in module_list:
    if env['module_' + x + '_enabled'] != "yes":
        continue
    tmppath = "./modules/" + x
    sys.path.append(tmppath)
    env.current_module = x
    import config
    if (config.can_build(selected_platform)):
        config.configure(env)
        env.module_list.append(x)
    sys.path.remove(tmppath)
    sys.modules.pop('config')

The config.py file should be in the root of each named module folder. I had copied a custom module incorrectly, leaving the config file in a sub-folder. This seems to have been the cause of the error.