Fix various bugs and start with the module loader