use MainModules debug function, not the global one