Friday, June 29, 2018

This week's extremely annoying and catastrophic bug

Somehow - and I have no idea how it happened - my Windows PATH environment variable got completely cleared.

The PATH variable is a list of folders on the hard drive that are accessed, in order, when I type a command at a command line (among other things).  So if I have a command window open and type "python" to start python, Windows will look for a program named python.exe (or .bat, or .cmd) in my current location.  If it finds one, it starts it.  If it does not find python there, it looks in the first folder of that PATH variable.  If Windows finds a python program there, it runs it.  If not, it looks in the next folder in that list, and so on.

I have probably a dozen commercial tools like python installed that use this.  I also have a couple of dozen batch and command files I have written to do repetitive tasks that I put in c:\windows\system32 (since that is always in the PATH) so they are always accessible.

But since that list got wiped, this all broke.  And the only way I have to restore it is to find broken applications, one at a time, that have dependencies on that PATH variable to work right.  When they fail, I have to either repair the application, reinstall it or manually figure out what went wrong and fix it myself.

Frankly, this has taken a tremendous amount of my time this week and I honestly think I might have been better just reinstalling everything on my C: drive from the ground up.  I keep all my data on a different drive so I wouldn't be that far behind the curve when done.  But at this point I have most of my key applications fixed so I think I will stay on my current path.

But this really messed up my week.  Sigh.

Questions, comments, concerns and criticisms always welcome,
John

No comments:

Post a Comment