The Py_SetPath call changes the embedded pathing. As far as I can tell it needs both the python.exe directory and the python directory/python3.XX after unzipping python3.XX.zip where the modules are ...
With python 3.13.0, you've got this error message when trying to run py4web. It seems that the cgi and cgitb modules, deprecated in Python 3.11, has just been removed (see similar problems with ...