Please avoid global and keep 'hiddenimports' and 'datas' declaration at the top of the modules as empty lists.