pypiwin32: does not check existence of pywin32_system32 in path before setting
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
on pypi, the packages have a line in the pywin32.pth file:
import os;os.environ["PATH"]+=(';'+os.path.join(sitedir,"pywin32_system32"))
however, when you have an application that reloads the modules without exiting the python process, this will cause the path to ultimately over-run the os.environ['PATH'] buffer.
The fix would be to change that line with:
import os;os.environ["PATH"]+=(';'+os.path.join(sitedir,"pywin32_system32")) if "pywin32_system32" not in os.environ["PATH"] else ''
ultimately when the buffer over-runs, all types of bad things happen to the running application.
Old Bugs - new issues at https://github.com/mhammond/pywin32/issues: #740