Is it possible there are any non-acsii filenames involved - either where you put the program, the username of the Portuguese machine, or any of the TEMPDIRs? There was a fix for that made quite recently but it hasn’t been released yet. I’ve built a wheel with the changes included so you can try it here. Be sure to uninstall your current PyInstaller before installing that one as pip gets a bit confused by local distributions.
The change I think it is is bootloader: pyi_path_fullpath: use _wfullpath() #5189 . Basically the bootloader (the little program which loads Python and runs your code) used an ascii-only data type to handle filenames which obviously means that it will fall to bits on encountering anything unicode. It’s written in C though which is why you can’t just install from Github. PyInstaller 4.1 is supposed to be released very soon though (actually it should have been released already) …