You get one apology (and a correction) because
DOS.EnvStr() effectively starts form one, despite what the documentation says.
For some reason my previous test was giving correct results even for EnvStr(0). In a new even simpler one it just returns an empty string (as do anything other than [1..EnvCount]).
As for this:
the discussion has alway been about the child process and not about the parent process that is what aprocess.environment does lol
That has been exactly my contention all along! It's now clear that we have been talking at cross-purposes. If you had started by saying: "I am running
env with a TProcess to check what the passed environment looks like and ..." we would not have wasted so many electrons.
So let's just leave it here, forget the hot words caused by temper and close the discussion, shall we?