Important but Annoying System Changes

I'm pretty serious about changes and I know when a change is important or maybe just not that important. Today I fixed an issue with setting the shell PATH variable for shell commands executed via PHP that has been bugging me for a long time.
It was messed up. I had to set the PATH using putenv("PATH=...")
, but when you do that getenv("PATH")
won't return the same value, but exec("echo $PATH")
will. It's nice to figure this type of thing out, but I don't like it when I know the answer but it doesn't entirely make sense. This is the acceptance part of being a good developer. Sometimes you just let it go and move on to write a blog post about it.